diff --git a/GNUmakefile b/GNUmakefile index b29ff6758..554d2ded0 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -363,7 +363,7 @@ test-envoy-integ: $(ENVOY_INTEG_DEPS) @$(SHELL) $(CURDIR)/test/integration/connect/envoy/run-tests.sh proto: - protoc agent/connect/ca/plugin/*.proto --gofast_out=plugins=grpc,Mgoogle/protobuf/duration.proto=github.com/gogo/protobuf/types:../../.. + protoc agent/connect/ca/plugin/*.proto --gofast_out=plugins=grpc:../../.. .PHONY: all ci bin dev dist cov test test-ci test-internal test-install-deps cover format vet ui static-assets tools .PHONY: docker-images go-build-image ui-build-image static-assets-docker consul-docker ui-docker diff --git a/agent/cache-types/connect_ca_leaf.go b/agent/cache-types/connect_ca_leaf.go index 84349f543..64a9edb7e 100644 --- a/agent/cache-types/connect_ca_leaf.go +++ b/agent/cache-types/connect_ca_leaf.go @@ -527,8 +527,7 @@ func (c *ConnectCALeaf) generateNewLeaf(req *ConnectCALeafRequest, } // Create a CSR. - serviceName := fmt.Sprintf("%s.service.%s.%s", req.Service, req.Datacenter, "consul") - csr, err := connect.CreateCSR(serviceName, id, pk) + csr, err := connect.CreateCSR(id, pk) if err != nil { return result, err } diff --git a/agent/config/builder.go b/agent/config/builder.go index f1878690c..297d65e45 100644 --- a/agent/config/builder.go +++ b/agent/config/builder.go @@ -584,17 +584,6 @@ func (b *Builder) Build() (rt RuntimeConfig, err error) { "tls_server_name": "TLSServerName", "tls_skip_verify": "TLSSkipVerify", - // AWS ACM PCA config - "access_key_id": "AccessKeyID", - "secret_access_key": "SecretAccessKey", - "region": "Region", - "sleep_time": "SleepTime", - "root_arn": "RootARN", - "intermediate_arn": "IntermediateTemplateARN", - "key_algorithm": "KeyAlgorithm", - "signing_algorithm": "SigningAlgorithm", - "delete_on_exit": "DeleteOnExit", - // Common CA config "leaf_cert_ttl": "LeafCertTTL", "csr_max_per_second": "CSRMaxPerSecond", @@ -1110,7 +1099,6 @@ func (b *Builder) Validate(rt RuntimeConfig) error { "": true, structs.ConsulCAProvider: true, structs.VaultCAProvider: true, - structs.AWSCAProvider: true, } if _, ok := validCAProviders[rt.ConnectCAProvider]; !ok { return fmt.Errorf("%s is not a valid CA provider", rt.ConnectCAProvider) @@ -1124,10 +1112,6 @@ func (b *Builder) Validate(rt RuntimeConfig) error { if _, err := ca.ParseVaultCAConfig(rt.ConnectCAConfig); err != nil { return err } - case structs.AWSCAProvider: - if _, err := ca.ParseAWSCAConfig(rt.ConnectCAConfig); err != nil { - return err - } } } diff --git a/agent/connect/ca/aws_pca.go b/agent/connect/ca/aws_pca.go deleted file mode 100644 index 94b86cc54..000000000 --- a/agent/connect/ca/aws_pca.go +++ /dev/null @@ -1,438 +0,0 @@ -package ca - -import ( - "crypto/x509" - "fmt" - "log" - "regexp" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/service/acmpca" - - "github.com/hashicorp/consul/agent/connect" - "github.com/hashicorp/consul/agent/structs" -) - -const ( - RootTemplateARN = "arn:aws:acm-pca:::template/RootCACertificate/V1" - IntermediateTemplateARN = "arn:aws:acm-pca:::template/SubordinateCACertificate_PathLen0/V1" - LeafTemplateARN = "arn:aws:acm-pca:::template/EndEntityCertificate/V1" -) - -const ( - RootValidity = 5 * 365 * 24 * time.Hour - IntermediateValidity = 1 * 365 * 24 * time.Hour -) - -type AmazonPCA struct { - arn string - pcaType string - keyAlgorithm string - signingAlgorithm string - sleepTime time.Duration - certPEM string - chainPEM string - client *acmpca.ACMPCA - logger *log.Logger -} - -func NewAmazonPCA(client *acmpca.ACMPCA, config *structs.AWSCAProviderConfig, arn string, pcaType string, - keyAlgorithm string, signingAlgorithm string, logger *log.Logger) *AmazonPCA { - sleepTime, err := time.ParseDuration(config.SleepTime) - if err != nil { - sleepTime = 5 * time.Second - } - return &AmazonPCA{arn: arn, pcaType: pcaType, client: client, logger: logger, - keyAlgorithm: keyAlgorithm, signingAlgorithm: signingAlgorithm, sleepTime: sleepTime} -} - -func LoadAmazonPCA(client *acmpca.ACMPCA, config *structs.AWSCAProviderConfig, arn string, pcaType string, - clusterId string, keyAlgorithm string, signingAlgorithm string, logger *log.Logger) (*AmazonPCA, error) { - pca := NewAmazonPCA(client, config, arn, pcaType, keyAlgorithm, signingAlgorithm, logger) - output, err := pca.describe() - if err != nil { - return nil, err - } - - warned := false - if *output.CertificateAuthority.Status != acmpca.CertificateAuthorityStatusActive { - return nil, fmt.Errorf("the specified PCA is not active: status is %s", - *output.CertificateAuthority.Status) - } - if *output.CertificateAuthority.CertificateAuthorityConfiguration.Subject.CommonName != - GetCommonName(pcaType, clusterId) { - logger.Printf("[WARN] name of specified PCA '%s' does not match expected '%s'", - *output.CertificateAuthority.CertificateAuthorityConfiguration.Subject.CommonName, - GetCommonName(pcaType, clusterId)) - warned = true - } - if *output.CertificateAuthority.CertificateAuthorityConfiguration.KeyAlgorithm != keyAlgorithm { - logger.Printf("[WARN] specified PCA is using an unexpected key algorithm: expected=%s actual=%s", - keyAlgorithm, *output.CertificateAuthority.CertificateAuthorityConfiguration.KeyAlgorithm) - warned = true - } - if *output.CertificateAuthority.CertificateAuthorityConfiguration.SigningAlgorithm != signingAlgorithm { - logger.Printf("[WARN] specified PCA is using an unexpected signing algorithm: expected=%s actual=%s", - signingAlgorithm, *output.CertificateAuthority.CertificateAuthorityConfiguration.SigningAlgorithm) - warned = true - } - - if warned { - logger.Print("[WARN] existing PCA failed some preflight checks, trying to continue anyway") - } else { - logger.Print("[WARN] existing PCA passed all preflight checks") - } - return pca, nil -} - -func FindAmazonPCA(client *acmpca.ACMPCA, config *structs.AWSCAProviderConfig, pcaType string, clusterId string, - keyAlgorithm string, signingAlgorithm string, logger *log.Logger) (*AmazonPCA, error) { - var name string = GetCommonName(pcaType, clusterId) - var nextToken *string - for { - input := acmpca.ListCertificateAuthoritiesInput{ - MaxResults: aws.Int64(100), - NextToken: nextToken, - } - logger.Print("[DEBUG] listing existing certificate authorities") - output, err := client.ListCertificateAuthorities(&input) - if err != nil { - logger.Printf("[ERR] error searching certificate authorities: %s", err.Error()) - return nil, err - } - - for _, ca := range output.CertificateAuthorities { - if *ca.CertificateAuthorityConfiguration.Subject.CommonName == name && - *ca.CertificateAuthorityConfiguration.KeyAlgorithm == keyAlgorithm && - *ca.CertificateAuthorityConfiguration.SigningAlgorithm == signingAlgorithm && - *ca.Status == acmpca.CertificateAuthorityStatusActive { - logger.Printf("[INFO] found an existing active CA %s", *ca.Arn) - return NewAmazonPCA(client, config, *ca.Arn, pcaType, *ca.CertificateAuthorityConfiguration.KeyAlgorithm, - *ca.CertificateAuthorityConfiguration.SigningAlgorithm, logger), nil - } - } - - nextToken = output.NextToken - if nextToken == nil { - break - } - } - - logger.Print("[WARN] no existing active CA found") - return nil, nil // not found -} - -func CreateAmazonPCA(client *acmpca.ACMPCA, config *structs.AWSCAProviderConfig, pcaType string, clusterId string, - keyAlgorithm string, signingAlgorithm string, logger *log.Logger) (*AmazonPCA, error) { - commonName := GetCommonName(pcaType, clusterId) - createInput := acmpca.CreateCertificateAuthorityInput{ - CertificateAuthorityType: aws.String(pcaType), - CertificateAuthorityConfiguration: &acmpca.CertificateAuthorityConfiguration{ - Subject: &acmpca.ASN1Subject{ - CommonName: aws.String(commonName), - }, - KeyAlgorithm: aws.String(keyAlgorithm), - SigningAlgorithm: aws.String(signingAlgorithm), - }, - RevocationConfiguration: &acmpca.RevocationConfiguration{ - CrlConfiguration: &acmpca.CrlConfiguration{ - Enabled: aws.Bool(false), - }, - }, - Tags: []*acmpca.Tag{ - {Key: aws.String("ClusterID"), Value: aws.String(clusterId)}, - }, - } - - logger.Printf("[DEBUG] creating new PCA %s", commonName) - createOutput, err := client.CreateCertificateAuthority(&createInput) - if err != nil { - return nil, err - } - - // wait for PCA to be created - newARN := *createOutput.CertificateAuthorityArn - for { - logger.Printf("[DEBUG] checking to see if PCA %s is ready", newARN) - - describeInput := acmpca.DescribeCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(newARN), - } - - describeOutput, err := client.DescribeCertificateAuthority(&describeInput) - if err != nil { - logger.Printf("[ERR] error describing PCA: %s", err.Error()) - if err.(awserr.Error).Code() != acmpca.ErrCodeRequestInProgressException { - return nil, fmt.Errorf("error waiting for PCA to be created: %s", err) - } - } - - if *describeOutput.CertificateAuthority.Status == acmpca.CertificateAuthorityStatusPendingCertificate { - logger.Printf("[DEBUG] new PCA %s is ready to accept a certificate", newARN) - return NewAmazonPCA(client, config, newARN, pcaType, keyAlgorithm, signingAlgorithm, logger), nil - } - - logger.Print("[DEBUG] sleeping until certificate is ready") - time.Sleep(5 * time.Second) // TODO: get from provider config - } -} - -func (pca *AmazonPCA) describe() (*acmpca.DescribeCertificateAuthorityOutput, error) { - input := &acmpca.DescribeCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(pca.arn), - } - - return pca.client.DescribeCertificateAuthority(input) -} - -func (pca *AmazonPCA) GetCSR() (string, error) { - input := &acmpca.GetCertificateAuthorityCsrInput{ - CertificateAuthorityArn: aws.String(pca.arn), - } - pca.logger.Printf("[DEBUG] retrieving CSR for %s", pca.arn) - output, err := pca.client.GetCertificateAuthorityCsr(input) - if err != nil { - pca.logger.Printf("[ERR] error retrieving CSR: %s", err.Error()) - return "", err - } - - return *output.Csr, nil -} - -func (pca *AmazonPCA) SetCert(certPEM string, chainPEM string) error { - chainBytes := []byte(chainPEM) - if chainPEM == "" { - chainBytes = nil - } - input := acmpca.ImportCertificateAuthorityCertificateInput{ - CertificateAuthorityArn: aws.String(pca.arn), - Certificate: []byte(certPEM), - CertificateChain: chainBytes, - } - - pca.logger.Printf("[DEBUG] uploading certificate for %s", pca.arn) - _, err := pca.client.ImportCertificateAuthorityCertificate(&input) - if err != nil { - pca.logger.Printf("[ERR] error importing certificates: %s", err.Error()) - return err - } - - pca.certPEM = certPEM - pca.chainPEM = chainPEM - - return nil -} - -func (pca *AmazonPCA) getCerts() error { - if pca.certPEM == "" || pca.chainPEM == "" { - input := &acmpca.GetCertificateAuthorityCertificateInput{ - CertificateAuthorityArn: aws.String(pca.arn), - } - - output, err := pca.client.GetCertificateAuthorityCertificate(input) - if err != nil { - return err - } - - pca.certPEM = *output.Certificate - pca.chainPEM = *output.CertificateChain - } - - return nil -} - -func (pca *AmazonPCA) Certificate() string { - if pca.certPEM == "" { - _ = pca.getCerts() - } - return pca.certPEM -} - -func (pca *AmazonPCA) CertificateChain() string { - if pca.chainPEM == "" { - _ = pca.getCerts() - } - return pca.certPEM -} - -func (pca *AmazonPCA) Generate(signingPCA *AmazonPCA) error { - csrPEM, err := pca.GetCSR() - if err != nil { - return err - } - - templateARN := GetTemplateARN(pca.pcaType) - chainPEM := "" - validity := RootValidity - if pca.pcaType == acmpca.CertificateAuthorityTypeSubordinate { - chainPEM = signingPCA.Certificate() - validity = IntermediateValidity - } - - newCertPEM, err := signingPCA.Sign(csrPEM, templateARN, validity) - if err != nil { - return err - } - - err = pca.SetCert(newCertPEM, chainPEM) - return err -} - -func (pca *AmazonPCA) Sign(csrPEM string, templateARN string, validity time.Duration) (string, error) { - issueInput := acmpca.IssueCertificateInput{ - CertificateAuthorityArn: aws.String(pca.arn), - Csr: []byte(csrPEM), - SigningAlgorithm: aws.String(pca.signingAlgorithm), - TemplateArn: aws.String(templateARN), - Validity: &acmpca.Validity{ - Value: aws.Int64(int64(validity.Seconds() / 86400.0)), - Type: aws.String(acmpca.ValidityPeriodTypeDays), - }, - } - - csr, err := connect.ParseCSR(csrPEM) - if err != nil { - return "", fmt.Errorf("unable to parse CSR: %s", err) - } - - pca.logger.Printf("[DEBUG] issuing certificate for %s with %s", csr.Subject.String(), pca.arn) - issueOutput, err := pca.client.IssueCertificate(&issueInput) - if err != nil { - pca.logger.Printf("[ERR] error issuing certificate: %s", err.Error()) - return "", fmt.Errorf("error issuing certificate from PCA: %s", err) - } - - // wait for certificate to be created - for { - pca.logger.Printf("[DEBUG] checking to see if certificate %s is ready", *issueOutput.CertificateArn) - - certInput := acmpca.GetCertificateInput{ - CertificateAuthorityArn: aws.String(pca.arn), - CertificateArn: issueOutput.CertificateArn, - } - certOutput, err := pca.client.GetCertificate(&certInput) - if err != nil { - if err.(awserr.Error).Code() != acmpca.ErrCodeRequestInProgressException { - pca.logger.Printf("[ERR] error retrieving new certificate from %s: %s", - *issueOutput.CertificateArn, err.Error()) - return "", fmt.Errorf("error retrieving certificate from PCA: %s", err) - } - } - - if certOutput.Certificate != nil { - pca.logger.Printf("[DEBUG] certificate is ready, ARN is %s", *issueOutput.CertificateArn) - - newCert, err := connect.ParseCert(*certOutput.Certificate) - if err == nil { - pca.logger.Printf("[DEBUG] certificate created: commonName=%s subjectKey=%s authorityKey=%s", - newCert.Subject.CommonName, - connect.HexString(newCert.SubjectKeyId), - connect.HexString(newCert.AuthorityKeyId)) - } - - return *certOutput.Certificate, nil - } - - pca.logger.Printf("[DEBUG] sleeping for %s until certificate is ready", pca.sleepTime) - time.Sleep(pca.sleepTime) - } -} - -func (pca *AmazonPCA) SignLeaf(csrPEM string, validity time.Duration) (string, error) { - certPEM, err := pca.Sign(csrPEM, LeafTemplateARN, validity) - return certPEM, err -} - -func (pca *AmazonPCA) SignIntermediate(csrPEM string) (string, error) { - certPEM, err := pca.Sign(csrPEM, IntermediateTemplateARN, IntermediateValidity) - return certPEM, err -} - -func (pca *AmazonPCA) SignRoot(csrPEM string) (string, error) { - certPEM, err := pca.Sign(csrPEM, RootTemplateARN, RootValidity) - return certPEM, err -} - -func (pca *AmazonPCA) Disable() error { - input := acmpca.UpdateCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(pca.arn), - Status: aws.String(acmpca.CertificateAuthorityStatusDisabled), - } - pca.logger.Printf("[INFO] disabling PCA %s", pca.arn) - _, err := pca.client.UpdateCertificateAuthority(&input) - - return err -} - -func (pca *AmazonPCA) Enable() error { - input := acmpca.UpdateCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(pca.arn), - Status: aws.String(acmpca.CertificateAuthorityStatusActive), - } - pca.logger.Printf("[INFO] enabling PCA %s", pca.arn) - _, err := pca.client.UpdateCertificateAuthority(&input) - - return err -} - -func (pca *AmazonPCA) Delete() error { - input := acmpca.DeleteCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(pca.arn), - } - pca.logger.Printf("[INFO] deleting PCA %s", pca.arn) - _, err := pca.client.DeleteCertificateAuthority(&input) - - return err -} - -func (pca *AmazonPCA) Undelete() error { - input := acmpca.RestoreCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(pca.arn), - } - pca.logger.Printf("[INFO] undeleting PCA %s", pca.arn) - _, err := pca.client.RestoreCertificateAuthority(&input) - - return err -} - -// utility functions - -func GetCommonName(pcaType string, clusterId string) string { - return fmt.Sprintf("Consul %s %s", pcaType, clusterId) -} - -func GetTemplateARN(pcaType string) string { - if pcaType == acmpca.CertificateAuthorityTypeRoot { - return RootTemplateARN - } else { - return IntermediateTemplateARN - } -} - -func IsValidARN(arn string) bool { - const PcaArnRegex = "^arn:([\\w-]+):([\\w-]+):(\\w{2}-\\w+-\\d+):(\\d+):(?:([\\w-]+)[/:])?([[:xdigit:]]{8}-[[:xdigit:]]{4}-[[:xdigit:]]{4}-[[:xdigit:]]{4}-[[:xdigit:]]{12})$" - - matched, _ := regexp.MatchString(PcaArnRegex, arn) - return matched -} - -func ToSignatureAlgorithm(algo string) x509.SignatureAlgorithm { - switch algo { - case acmpca.SigningAlgorithmSha256withrsa: - return x509.SHA256WithRSA - case acmpca.SigningAlgorithmSha384withrsa: - return x509.SHA384WithRSA - case acmpca.SigningAlgorithmSha512withrsa: - return x509.SHA512WithRSA - case acmpca.SigningAlgorithmSha256withecdsa: - return x509.ECDSAWithSHA256 - case acmpca.SigningAlgorithmSha384withecdsa: - return x509.ECDSAWithSHA384 - case acmpca.SigningAlgorithmSha512withecdsa: - return x509.ECDSAWithSHA512 - default: - return x509.SHA256WithRSA - } -} diff --git a/agent/connect/ca/mock_Provider.go b/agent/connect/ca/mock_Provider.go index 9018a2c8c..e8b9e5892 100644 --- a/agent/connect/ca/mock_Provider.go +++ b/agent/connect/ca/mock_Provider.go @@ -3,7 +3,6 @@ package ca import mock "github.com/stretchr/testify/mock" -import time "time" import x509 "crypto/x509" // MockProvider is an autogenerated mock type for the Provider type @@ -158,20 +157,6 @@ func (_m *MockProvider) GenerateRoot() error { return r0 } -// MinLifetime provides a mock function with given fields: -func (_m *MockProvider) MinLifetime() time.Duration { - ret := _m.Called() - - var r0 time.Duration - if rf, ok := ret.Get(0).(func() time.Duration); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(time.Duration) - } - - return r0 -} - // SetIntermediate provides a mock function with given fields: intermediatePEM, rootPEM func (_m *MockProvider) SetIntermediate(intermediatePEM string, rootPEM string) error { ret := _m.Called(intermediatePEM, rootPEM) @@ -227,17 +212,3 @@ func (_m *MockProvider) SignIntermediate(_a0 *x509.CertificateRequest) (string, return r0, r1 } - -// SupportsCrossSigning provides a mock function with given fields: -func (_m *MockProvider) SupportsCrossSigning() bool { - ret := _m.Called() - - var r0 bool - if rf, ok := ret.Get(0).(func() bool); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(bool) - } - - return r0 -} diff --git a/agent/connect/ca/plugin/provider.pb.go b/agent/connect/ca/plugin/provider.pb.go index 92d78b5e4..8c15dcdc0 100644 --- a/agent/connect/ca/plugin/provider.pb.go +++ b/agent/connect/ca/plugin/provider.pb.go @@ -1,18 +1,19 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: agent/connect/ca/plugin/provider.proto -package plugin +package plugin // import "github.com/hashicorp/consul/agent/connect/ca/plugin" + +import proto "github.com/golang/protobuf/proto" +import fmt "fmt" +import math "math" import ( - context "context" - fmt "fmt" - types "github.com/gogo/protobuf/types" - proto "github.com/golang/protobuf/proto" + context "golang.org/x/net/context" grpc "google.golang.org/grpc" - io "io" - math "math" ) +import io "io" + // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf @@ -37,7 +38,7 @@ func (m *ConfigureRequest) Reset() { *m = ConfigureRequest{} } func (m *ConfigureRequest) String() string { return proto.CompactTextString(m) } func (*ConfigureRequest) ProtoMessage() {} func (*ConfigureRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{0} + return fileDescriptor_provider_8ff2d2670790989c, []int{0} } func (m *ConfigureRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -54,8 +55,8 @@ func (m *ConfigureRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, er return b[:n], nil } } -func (m *ConfigureRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_ConfigureRequest.Merge(m, src) +func (dst *ConfigureRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_ConfigureRequest.Merge(dst, src) } func (m *ConfigureRequest) XXX_Size() int { return m.Size() @@ -99,7 +100,7 @@ func (m *SetIntermediateRequest) Reset() { *m = SetIntermediateRequest{} func (m *SetIntermediateRequest) String() string { return proto.CompactTextString(m) } func (*SetIntermediateRequest) ProtoMessage() {} func (*SetIntermediateRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{1} + return fileDescriptor_provider_8ff2d2670790989c, []int{1} } func (m *SetIntermediateRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -116,8 +117,8 @@ func (m *SetIntermediateRequest) XXX_Marshal(b []byte, deterministic bool) ([]by return b[:n], nil } } -func (m *SetIntermediateRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_SetIntermediateRequest.Merge(m, src) +func (dst *SetIntermediateRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetIntermediateRequest.Merge(dst, src) } func (m *SetIntermediateRequest) XXX_Size() int { return m.Size() @@ -153,7 +154,7 @@ func (m *SignRequest) Reset() { *m = SignRequest{} } func (m *SignRequest) String() string { return proto.CompactTextString(m) } func (*SignRequest) ProtoMessage() {} func (*SignRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{2} + return fileDescriptor_provider_8ff2d2670790989c, []int{2} } func (m *SignRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -170,8 +171,8 @@ func (m *SignRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) return b[:n], nil } } -func (m *SignRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_SignRequest.Merge(m, src) +func (dst *SignRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignRequest.Merge(dst, src) } func (m *SignRequest) XXX_Size() int { return m.Size() @@ -200,7 +201,7 @@ func (m *SignIntermediateRequest) Reset() { *m = SignIntermediateRequest func (m *SignIntermediateRequest) String() string { return proto.CompactTextString(m) } func (*SignIntermediateRequest) ProtoMessage() {} func (*SignIntermediateRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{3} + return fileDescriptor_provider_8ff2d2670790989c, []int{3} } func (m *SignIntermediateRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -217,8 +218,8 @@ func (m *SignIntermediateRequest) XXX_Marshal(b []byte, deterministic bool) ([]b return b[:n], nil } } -func (m *SignIntermediateRequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_SignIntermediateRequest.Merge(m, src) +func (dst *SignIntermediateRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignIntermediateRequest.Merge(dst, src) } func (m *SignIntermediateRequest) XXX_Size() int { return m.Size() @@ -247,7 +248,7 @@ func (m *CrossSignCARequest) Reset() { *m = CrossSignCARequest{} } func (m *CrossSignCARequest) String() string { return proto.CompactTextString(m) } func (*CrossSignCARequest) ProtoMessage() {} func (*CrossSignCARequest) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{4} + return fileDescriptor_provider_8ff2d2670790989c, []int{4} } func (m *CrossSignCARequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -264,8 +265,8 @@ func (m *CrossSignCARequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, return b[:n], nil } } -func (m *CrossSignCARequest) XXX_Merge(src proto.Message) { - xxx_messageInfo_CrossSignCARequest.Merge(m, src) +func (dst *CrossSignCARequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_CrossSignCARequest.Merge(dst, src) } func (m *CrossSignCARequest) XXX_Size() int { return m.Size() @@ -294,7 +295,7 @@ func (m *ActiveRootResponse) Reset() { *m = ActiveRootResponse{} } func (m *ActiveRootResponse) String() string { return proto.CompactTextString(m) } func (*ActiveRootResponse) ProtoMessage() {} func (*ActiveRootResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{5} + return fileDescriptor_provider_8ff2d2670790989c, []int{5} } func (m *ActiveRootResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -311,8 +312,8 @@ func (m *ActiveRootResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, return b[:n], nil } } -func (m *ActiveRootResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_ActiveRootResponse.Merge(m, src) +func (dst *ActiveRootResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_ActiveRootResponse.Merge(dst, src) } func (m *ActiveRootResponse) XXX_Size() int { return m.Size() @@ -341,7 +342,7 @@ func (m *GenerateIntermediateCSRResponse) Reset() { *m = GenerateInterme func (m *GenerateIntermediateCSRResponse) String() string { return proto.CompactTextString(m) } func (*GenerateIntermediateCSRResponse) ProtoMessage() {} func (*GenerateIntermediateCSRResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{6} + return fileDescriptor_provider_8ff2d2670790989c, []int{6} } func (m *GenerateIntermediateCSRResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -358,8 +359,8 @@ func (m *GenerateIntermediateCSRResponse) XXX_Marshal(b []byte, deterministic bo return b[:n], nil } } -func (m *GenerateIntermediateCSRResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_GenerateIntermediateCSRResponse.Merge(m, src) +func (dst *GenerateIntermediateCSRResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GenerateIntermediateCSRResponse.Merge(dst, src) } func (m *GenerateIntermediateCSRResponse) XXX_Size() int { return m.Size() @@ -388,7 +389,7 @@ func (m *ActiveIntermediateResponse) Reset() { *m = ActiveIntermediateRe func (m *ActiveIntermediateResponse) String() string { return proto.CompactTextString(m) } func (*ActiveIntermediateResponse) ProtoMessage() {} func (*ActiveIntermediateResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{7} + return fileDescriptor_provider_8ff2d2670790989c, []int{7} } func (m *ActiveIntermediateResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -405,8 +406,8 @@ func (m *ActiveIntermediateResponse) XXX_Marshal(b []byte, deterministic bool) ( return b[:n], nil } } -func (m *ActiveIntermediateResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_ActiveIntermediateResponse.Merge(m, src) +func (dst *ActiveIntermediateResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_ActiveIntermediateResponse.Merge(dst, src) } func (m *ActiveIntermediateResponse) XXX_Size() int { return m.Size() @@ -435,7 +436,7 @@ func (m *GenerateIntermediateResponse) Reset() { *m = GenerateIntermedia func (m *GenerateIntermediateResponse) String() string { return proto.CompactTextString(m) } func (*GenerateIntermediateResponse) ProtoMessage() {} func (*GenerateIntermediateResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{8} + return fileDescriptor_provider_8ff2d2670790989c, []int{8} } func (m *GenerateIntermediateResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -452,8 +453,8 @@ func (m *GenerateIntermediateResponse) XXX_Marshal(b []byte, deterministic bool) return b[:n], nil } } -func (m *GenerateIntermediateResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_GenerateIntermediateResponse.Merge(m, src) +func (dst *GenerateIntermediateResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GenerateIntermediateResponse.Merge(dst, src) } func (m *GenerateIntermediateResponse) XXX_Size() int { return m.Size() @@ -482,7 +483,7 @@ func (m *SignResponse) Reset() { *m = SignResponse{} } func (m *SignResponse) String() string { return proto.CompactTextString(m) } func (*SignResponse) ProtoMessage() {} func (*SignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{9} + return fileDescriptor_provider_8ff2d2670790989c, []int{9} } func (m *SignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -499,8 +500,8 @@ func (m *SignResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) return b[:n], nil } } -func (m *SignResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_SignResponse.Merge(m, src) +func (dst *SignResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignResponse.Merge(dst, src) } func (m *SignResponse) XXX_Size() int { return m.Size() @@ -529,7 +530,7 @@ func (m *SignIntermediateResponse) Reset() { *m = SignIntermediateRespon func (m *SignIntermediateResponse) String() string { return proto.CompactTextString(m) } func (*SignIntermediateResponse) ProtoMessage() {} func (*SignIntermediateResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{10} + return fileDescriptor_provider_8ff2d2670790989c, []int{10} } func (m *SignIntermediateResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -546,8 +547,8 @@ func (m *SignIntermediateResponse) XXX_Marshal(b []byte, deterministic bool) ([] return b[:n], nil } } -func (m *SignIntermediateResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_SignIntermediateResponse.Merge(m, src) +func (dst *SignIntermediateResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SignIntermediateResponse.Merge(dst, src) } func (m *SignIntermediateResponse) XXX_Size() int { return m.Size() @@ -576,7 +577,7 @@ func (m *CrossSignCAResponse) Reset() { *m = CrossSignCAResponse{} } func (m *CrossSignCAResponse) String() string { return proto.CompactTextString(m) } func (*CrossSignCAResponse) ProtoMessage() {} func (*CrossSignCAResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{11} + return fileDescriptor_provider_8ff2d2670790989c, []int{11} } func (m *CrossSignCAResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -593,8 +594,8 @@ func (m *CrossSignCAResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, return b[:n], nil } } -func (m *CrossSignCAResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_CrossSignCAResponse.Merge(m, src) +func (dst *CrossSignCAResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_CrossSignCAResponse.Merge(dst, src) } func (m *CrossSignCAResponse) XXX_Size() int { return m.Size() @@ -612,100 +613,6 @@ func (m *CrossSignCAResponse) GetCrtPem() string { return "" } -type SupportsCrossSigningResponse struct { - SupportsCrossSigning bool `protobuf:"varint,1,opt,name=supports_cross_signing,json=supportsCrossSigning,proto3" json:"supports_cross_signing,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *SupportsCrossSigningResponse) Reset() { *m = SupportsCrossSigningResponse{} } -func (m *SupportsCrossSigningResponse) String() string { return proto.CompactTextString(m) } -func (*SupportsCrossSigningResponse) ProtoMessage() {} -func (*SupportsCrossSigningResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{12} -} -func (m *SupportsCrossSigningResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *SupportsCrossSigningResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_SupportsCrossSigningResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalTo(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *SupportsCrossSigningResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_SupportsCrossSigningResponse.Merge(m, src) -} -func (m *SupportsCrossSigningResponse) XXX_Size() int { - return m.Size() -} -func (m *SupportsCrossSigningResponse) XXX_DiscardUnknown() { - xxx_messageInfo_SupportsCrossSigningResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_SupportsCrossSigningResponse proto.InternalMessageInfo - -func (m *SupportsCrossSigningResponse) GetSupportsCrossSigning() bool { - if m != nil { - return m.SupportsCrossSigning - } - return false -} - -type MinLifetimeResponse struct { - MinLifetime *types.Duration `protobuf:"bytes,1,opt,name=min_lifetime,json=minLifetime,proto3" json:"min_lifetime,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *MinLifetimeResponse) Reset() { *m = MinLifetimeResponse{} } -func (m *MinLifetimeResponse) String() string { return proto.CompactTextString(m) } -func (*MinLifetimeResponse) ProtoMessage() {} -func (*MinLifetimeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{13} -} -func (m *MinLifetimeResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MinLifetimeResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MinLifetimeResponse.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalTo(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MinLifetimeResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MinLifetimeResponse.Merge(m, src) -} -func (m *MinLifetimeResponse) XXX_Size() int { - return m.Size() -} -func (m *MinLifetimeResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MinLifetimeResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MinLifetimeResponse proto.InternalMessageInfo - -func (m *MinLifetimeResponse) GetMinLifetime() *types.Duration { - if m != nil { - return m.MinLifetime - } - return nil -} - // Protobufs doesn't allow no req/resp so in the cases where there are // no arguments we use the Empty message. type Empty struct { @@ -718,7 +625,7 @@ func (m *Empty) Reset() { *m = Empty{} } func (m *Empty) String() string { return proto.CompactTextString(m) } func (*Empty) ProtoMessage() {} func (*Empty) Descriptor() ([]byte, []int) { - return fileDescriptor_94daeb7181770839, []int{14} + return fileDescriptor_provider_8ff2d2670790989c, []int{12} } func (m *Empty) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -735,8 +642,8 @@ func (m *Empty) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return b[:n], nil } } -func (m *Empty) XXX_Merge(src proto.Message) { - xxx_messageInfo_Empty.Merge(m, src) +func (dst *Empty) XXX_Merge(src proto.Message) { + xxx_messageInfo_Empty.Merge(dst, src) } func (m *Empty) XXX_Size() int { return m.Size() @@ -760,62 +667,9 @@ func init() { proto.RegisterType((*SignResponse)(nil), "plugin.SignResponse") proto.RegisterType((*SignIntermediateResponse)(nil), "plugin.SignIntermediateResponse") proto.RegisterType((*CrossSignCAResponse)(nil), "plugin.CrossSignCAResponse") - proto.RegisterType((*SupportsCrossSigningResponse)(nil), "plugin.SupportsCrossSigningResponse") - proto.RegisterType((*MinLifetimeResponse)(nil), "plugin.MinLifetimeResponse") proto.RegisterType((*Empty)(nil), "plugin.Empty") } -func init() { - proto.RegisterFile("agent/connect/ca/plugin/provider.proto", fileDescriptor_94daeb7181770839) -} - -var fileDescriptor_94daeb7181770839 = []byte{ - // 680 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x55, 0xdd, 0x4e, 0x13, 0x41, - 0x14, 0x76, 0x41, 0x5b, 0x38, 0xad, 0xa1, 0x19, 0x1a, 0x28, 0x15, 0x4b, 0xb3, 0x31, 0x80, 0x51, - 0x77, 0x23, 0x60, 0x88, 0xc6, 0x0b, 0xb1, 0x22, 0x21, 0x68, 0x82, 0x5b, 0xbd, 0xf1, 0xc2, 0x66, - 0x3b, 0x1d, 0x96, 0x49, 0xba, 0x33, 0xeb, 0xcc, 0x2c, 0x89, 0x6f, 0xe2, 0x23, 0x79, 0xa7, 0x8f, - 0x60, 0xf0, 0x45, 0xcc, 0xfe, 0x76, 0x77, 0xd9, 0xb2, 0x77, 0x9d, 0x33, 0xdf, 0xf7, 0x9d, 0x9f, - 0x9e, 0x6f, 0x16, 0xb6, 0x6d, 0x87, 0x30, 0x65, 0x62, 0xce, 0x18, 0xc1, 0xca, 0xc4, 0xb6, 0xe9, - 0x4d, 0x7d, 0x87, 0x32, 0xd3, 0x13, 0xfc, 0x8a, 0x4e, 0x88, 0x30, 0x3c, 0xc1, 0x15, 0x47, 0xb5, - 0x28, 0xdc, 0xed, 0x39, 0x9c, 0x3b, 0x53, 0x62, 0x86, 0xd1, 0xb1, 0x7f, 0x61, 0x4e, 0x7c, 0x61, - 0x2b, 0xca, 0x59, 0x84, 0xd3, 0xc7, 0xd0, 0x1a, 0x70, 0x76, 0x41, 0x1d, 0x5f, 0x10, 0x8b, 0x7c, - 0xf7, 0x89, 0x54, 0xe8, 0x21, 0x00, 0x9e, 0xfa, 0x52, 0x11, 0x31, 0xa2, 0x93, 0x8e, 0xd6, 0xd7, - 0x76, 0x97, 0xad, 0xe5, 0x38, 0x72, 0x3a, 0x41, 0xeb, 0x50, 0xa7, 0x72, 0x24, 0x38, 0x57, 0x9d, - 0x85, 0xbe, 0xb6, 0xbb, 0x64, 0xd5, 0xa8, 0xb4, 0x38, 0x57, 0x68, 0x0d, 0x6a, 0x38, 0xd4, 0xea, - 0x2c, 0xf6, 0xb5, 0xdd, 0xa6, 0x15, 0x9f, 0xf4, 0x6f, 0xb0, 0x36, 0x24, 0xea, 0x94, 0x29, 0x22, - 0x5c, 0x32, 0xa1, 0xb6, 0x4a, 0x33, 0x3d, 0x86, 0x16, 0xcd, 0x84, 0x47, 0x1e, 0x71, 0xe3, 0x7c, - 0x2b, 0xd9, 0xf8, 0x39, 0x71, 0xd1, 0x06, 0x2c, 0x05, 0x29, 0x43, 0xc8, 0x42, 0x08, 0xa9, 0x07, - 0xe7, 0x73, 0xe2, 0xea, 0x5b, 0xd0, 0x18, 0x52, 0x87, 0x25, 0xa2, 0x2d, 0x58, 0xc4, 0x52, 0x84, - 0x3a, 0x4d, 0x2b, 0xf8, 0xa9, 0x3f, 0x81, 0xf5, 0x00, 0x50, 0x56, 0xc1, 0x4d, 0xf0, 0x36, 0xa0, - 0x81, 0xe0, 0x52, 0x06, 0x8c, 0xc1, 0x51, 0x16, 0x27, 0x54, 0x8a, 0x13, 0x4a, 0x7f, 0x06, 0xe8, - 0x08, 0x2b, 0x7a, 0x45, 0x82, 0xde, 0x2d, 0x22, 0x3d, 0xce, 0x24, 0x09, 0x86, 0x83, 0x85, 0xca, - 0x34, 0x52, 0xc3, 0x22, 0x2c, 0xf2, 0x15, 0x6c, 0x9d, 0x10, 0x46, 0x84, 0xad, 0x48, 0xb6, 0x8e, - 0xc1, 0xd0, 0xca, 0x71, 0xa5, 0xc8, 0x71, 0xa5, 0x08, 0xb8, 0x2f, 0xa0, 0x1b, 0xa5, 0xca, 0x77, - 0x50, 0x95, 0xf2, 0x10, 0x36, 0xcb, 0x52, 0x56, 0x13, 0x77, 0xa0, 0x19, 0x0d, 0xb4, 0x0a, 0xb8, - 0x0f, 0x9d, 0x9b, 0x83, 0xad, 0x22, 0x19, 0xb0, 0x9a, 0x1b, 0x70, 0x15, 0xfe, 0x33, 0x6c, 0x0e, - 0x7d, 0xcf, 0xe3, 0x42, 0xc9, 0x94, 0x47, 0x99, 0x93, 0x12, 0x0f, 0x60, 0x4d, 0xc6, 0xf7, 0x23, - 0x1c, 0x00, 0x46, 0x32, 0x42, 0x84, 0x3a, 0x4b, 0x56, 0x5b, 0x96, 0xb0, 0xf5, 0x21, 0xac, 0x7e, - 0xa4, 0xec, 0x03, 0xbd, 0x20, 0x8a, 0xba, 0xb3, 0xaa, 0x5f, 0x43, 0xd3, 0xa5, 0x6c, 0x34, 0x8d, - 0xe3, 0xa1, 0x44, 0x63, 0x6f, 0xc3, 0x88, 0x6c, 0x64, 0x24, 0x36, 0x32, 0xde, 0xc5, 0x36, 0xb2, - 0x1a, 0xee, 0x4c, 0x45, 0xaf, 0xc3, 0xbd, 0x63, 0xd7, 0x53, 0x3f, 0xf6, 0x7e, 0xd7, 0x60, 0x61, - 0x70, 0x84, 0x0e, 0x60, 0x39, 0x75, 0x17, 0xea, 0x18, 0x91, 0x27, 0x8d, 0xa2, 0xe1, 0xba, 0xf7, - 0x93, 0x9b, 0x90, 0x8c, 0x9e, 0x42, 0x33, 0xf9, 0xdf, 0x42, 0x5f, 0xe5, 0xaf, 0x8b, 0xe8, 0x43, - 0x80, 0xd9, 0x1e, 0x16, 0xb1, 0xdd, 0xe4, 0x58, 0xb2, 0xaa, 0x9f, 0x60, 0x7d, 0xce, 0x46, 0x16, - 0x55, 0x76, 0x92, 0x63, 0xd5, 0x06, 0xbf, 0x81, 0x95, 0x82, 0xd3, 0x51, 0x2f, 0xe1, 0x96, 0x3f, - 0x01, 0xc5, 0x6e, 0x4e, 0x12, 0x57, 0xe5, 0x44, 0x0a, 0xf5, 0xe8, 0xf9, 0xae, 0x4a, 0xd7, 0xef, - 0x0c, 0xda, 0x65, 0xd5, 0x16, 0xa5, 0x1e, 0xdd, 0xd6, 0x5a, 0x2a, 0xf6, 0x1c, 0xee, 0x06, 0x7b, - 0x83, 0x56, 0xd3, 0x66, 0x66, 0xef, 0x4d, 0xb7, 0x9d, 0x0f, 0xc6, 0x94, 0x2f, 0xd0, 0x2a, 0x5a, - 0x03, 0x6d, 0x65, 0x91, 0x65, 0xc3, 0xe8, 0xcf, 0x07, 0xc4, 0xb2, 0xef, 0xa1, 0x91, 0x31, 0x0f, - 0x4a, 0xff, 0xdf, 0x9b, 0x4f, 0x56, 0xf7, 0x41, 0xe9, 0x5d, 0xac, 0xb3, 0x03, 0xf5, 0xc1, 0x94, - 0xd8, 0xcc, 0xf7, 0x2a, 0xd6, 0xeb, 0x0c, 0xda, 0x65, 0xee, 0x9b, 0x3b, 0xc7, 0x5b, 0xad, 0xfa, - 0x12, 0x1a, 0x19, 0xd3, 0x15, 0x35, 0xd2, 0x82, 0x4b, 0x8c, 0xf9, 0xf6, 0xf8, 0xd7, 0x75, 0x4f, - 0xfb, 0x73, 0xdd, 0xd3, 0xfe, 0x5e, 0xf7, 0xb4, 0x9f, 0xff, 0x7a, 0x77, 0xbe, 0xee, 0x3b, 0x54, - 0x5d, 0xfa, 0x63, 0x03, 0x73, 0xd7, 0xbc, 0xb4, 0xe5, 0x25, 0xc5, 0x5c, 0x78, 0xc1, 0x97, 0x51, - 0xfa, 0x53, 0x73, 0xce, 0x67, 0x72, 0x5c, 0x0b, 0x1d, 0xbc, 0xff, 0x3f, 0x00, 0x00, 0xff, 0xff, - 0xa1, 0xe1, 0x02, 0x3b, 0x48, 0x07, 0x00, 0x00, -} - // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn @@ -839,8 +693,6 @@ type CAClient interface { SignIntermediate(ctx context.Context, in *SignIntermediateRequest, opts ...grpc.CallOption) (*SignIntermediateResponse, error) CrossSignCA(ctx context.Context, in *CrossSignCARequest, opts ...grpc.CallOption) (*CrossSignCAResponse, error) Cleanup(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) - SupportsCrossSigning(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*SupportsCrossSigningResponse, error) - MinLifetime(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*MinLifetimeResponse, error) } type cAClient struct { @@ -950,24 +802,6 @@ func (c *cAClient) Cleanup(ctx context.Context, in *Empty, opts ...grpc.CallOpti return out, nil } -func (c *cAClient) SupportsCrossSigning(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*SupportsCrossSigningResponse, error) { - out := new(SupportsCrossSigningResponse) - err := c.cc.Invoke(ctx, "/plugin.CA/SupportsCrossSigning", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *cAClient) MinLifetime(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*MinLifetimeResponse, error) { - out := new(MinLifetimeResponse) - err := c.cc.Invoke(ctx, "/plugin.CA/MinLifetime", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // CAServer is the server API for CA service. type CAServer interface { Configure(context.Context, *ConfigureRequest) (*Empty, error) @@ -981,8 +815,6 @@ type CAServer interface { SignIntermediate(context.Context, *SignIntermediateRequest) (*SignIntermediateResponse, error) CrossSignCA(context.Context, *CrossSignCARequest) (*CrossSignCAResponse, error) Cleanup(context.Context, *Empty) (*Empty, error) - SupportsCrossSigning(context.Context, *Empty) (*SupportsCrossSigningResponse, error) - MinLifetime(context.Context, *Empty) (*MinLifetimeResponse, error) } func RegisterCAServer(s *grpc.Server, srv CAServer) { @@ -1187,42 +1019,6 @@ func _CA_Cleanup_Handler(srv interface{}, ctx context.Context, dec func(interfac return interceptor(ctx, in, info, handler) } -func _CA_SupportsCrossSigning_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Empty) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(CAServer).SupportsCrossSigning(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/plugin.CA/SupportsCrossSigning", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(CAServer).SupportsCrossSigning(ctx, req.(*Empty)) - } - return interceptor(ctx, in, info, handler) -} - -func _CA_MinLifetime_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(Empty) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(CAServer).MinLifetime(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/plugin.CA/MinLifetime", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(CAServer).MinLifetime(ctx, req.(*Empty)) - } - return interceptor(ctx, in, info, handler) -} - var _CA_serviceDesc = grpc.ServiceDesc{ ServiceName: "plugin.CA", HandlerType: (*CAServer)(nil), @@ -1271,14 +1067,6 @@ var _CA_serviceDesc = grpc.ServiceDesc{ MethodName: "Cleanup", Handler: _CA_Cleanup_Handler, }, - { - MethodName: "SupportsCrossSigning", - Handler: _CA_SupportsCrossSigning_Handler, - }, - { - MethodName: "MinLifetime", - Handler: _CA_MinLifetime_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "agent/connect/ca/plugin/provider.proto", @@ -1630,68 +1418,6 @@ func (m *CrossSignCAResponse) MarshalTo(dAtA []byte) (int, error) { return i, nil } -func (m *SupportsCrossSigningResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalTo(dAtA) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *SupportsCrossSigningResponse) MarshalTo(dAtA []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.SupportsCrossSigning { - dAtA[i] = 0x8 - i++ - if m.SupportsCrossSigning { - dAtA[i] = 1 - } else { - dAtA[i] = 0 - } - i++ - } - if m.XXX_unrecognized != nil { - i += copy(dAtA[i:], m.XXX_unrecognized) - } - return i, nil -} - -func (m *MinLifetimeResponse) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalTo(dAtA) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MinLifetimeResponse) MarshalTo(dAtA []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.MinLifetime != nil { - dAtA[i] = 0xa - i++ - i = encodeVarintProvider(dAtA, i, uint64(m.MinLifetime.Size())) - n1, err := m.MinLifetime.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err - } - i += n1 - } - if m.XXX_unrecognized != nil { - i += copy(dAtA[i:], m.XXX_unrecognized) - } - return i, nil -} - func (m *Empty) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1925,37 +1651,6 @@ func (m *CrossSignCAResponse) Size() (n int) { return n } -func (m *SupportsCrossSigningResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.SupportsCrossSigning { - n += 2 - } - if m.XXX_unrecognized != nil { - n += len(m.XXX_unrecognized) - } - return n -} - -func (m *MinLifetimeResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.MinLifetime != nil { - l = m.MinLifetime.Size() - n += 1 + l + sovProvider(uint64(l)) - } - if m.XXX_unrecognized != nil { - n += len(m.XXX_unrecognized) - } - return n -} - func (m *Empty) Size() (n int) { if m == nil { return 0 @@ -1996,7 +1691,7 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2024,7 +1719,7 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2034,9 +1729,6 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2056,7 +1748,7 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - v |= int(b&0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } @@ -2076,7 +1768,7 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } @@ -2085,9 +1777,6 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2105,9 +1794,6 @@ func (m *ConfigureRequest) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2136,7 +1822,7 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2164,7 +1850,7 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2174,9 +1860,6 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2196,7 +1879,7 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2206,9 +1889,6 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2223,9 +1903,6 @@ func (m *SetIntermediateRequest) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2254,7 +1931,7 @@ func (m *SignRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2282,7 +1959,7 @@ func (m *SignRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } @@ -2291,9 +1968,6 @@ func (m *SignRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2311,9 +1985,6 @@ func (m *SignRequest) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2342,7 +2013,7 @@ func (m *SignIntermediateRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2370,7 +2041,7 @@ func (m *SignIntermediateRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } @@ -2379,9 +2050,6 @@ func (m *SignIntermediateRequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2399,9 +2067,6 @@ func (m *SignIntermediateRequest) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2430,7 +2095,7 @@ func (m *CrossSignCARequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2458,7 +2123,7 @@ func (m *CrossSignCARequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - byteLen |= int(b&0x7F) << shift + byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { break } @@ -2467,9 +2132,6 @@ func (m *CrossSignCARequest) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + byteLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2487,9 +2149,6 @@ func (m *CrossSignCARequest) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2518,7 +2177,7 @@ func (m *ActiveRootResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2546,7 +2205,7 @@ func (m *ActiveRootResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2556,9 +2215,6 @@ func (m *ActiveRootResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2573,9 +2229,6 @@ func (m *ActiveRootResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2604,7 +2257,7 @@ func (m *GenerateIntermediateCSRResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2632,7 +2285,7 @@ func (m *GenerateIntermediateCSRResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2642,9 +2295,6 @@ func (m *GenerateIntermediateCSRResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2659,9 +2309,6 @@ func (m *GenerateIntermediateCSRResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2690,7 +2337,7 @@ func (m *ActiveIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2718,7 +2365,7 @@ func (m *ActiveIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2728,9 +2375,6 @@ func (m *ActiveIntermediateResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2745,9 +2389,6 @@ func (m *ActiveIntermediateResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2776,7 +2417,7 @@ func (m *GenerateIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2804,7 +2445,7 @@ func (m *GenerateIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2814,9 +2455,6 @@ func (m *GenerateIntermediateResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2831,9 +2469,6 @@ func (m *GenerateIntermediateResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2862,7 +2497,7 @@ func (m *SignResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2890,7 +2525,7 @@ func (m *SignResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2900,9 +2535,6 @@ func (m *SignResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -2917,9 +2549,6 @@ func (m *SignResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -2948,7 +2577,7 @@ func (m *SignIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2976,7 +2605,7 @@ func (m *SignIntermediateResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -2986,9 +2615,6 @@ func (m *SignIntermediateResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -3003,9 +2629,6 @@ func (m *SignIntermediateResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -3034,7 +2657,7 @@ func (m *CrossSignCAResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -3062,7 +2685,7 @@ func (m *CrossSignCAResponse) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - stringLen |= uint64(b&0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -3072,9 +2695,6 @@ func (m *CrossSignCAResponse) Unmarshal(dAtA []byte) error { return ErrInvalidLengthProvider } postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProvider - } if postIndex > l { return io.ErrUnexpectedEOF } @@ -3089,173 +2709,6 @@ func (m *CrossSignCAResponse) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SupportsCrossSigningResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProvider - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SupportsCrossSigningResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SupportsCrossSigningResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SupportsCrossSigning", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProvider - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.SupportsCrossSigning = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipProvider(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthProvider - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...) - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *MinLifetimeResponse) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProvider - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MinLifetimeResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MinLifetimeResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MinLifetime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProvider - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthProvider - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthProvider - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.MinLifetime == nil { - m.MinLifetime = &types.Duration{} - } - if err := m.MinLifetime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipProvider(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthProvider - } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -3284,7 +2737,7 @@ func (m *Empty) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - wire |= uint64(b&0x7F) << shift + wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } @@ -3307,9 +2760,6 @@ func (m *Empty) Unmarshal(dAtA []byte) error { if skippy < 0 { return ErrInvalidLengthProvider } - if (iNdEx + skippy) < 0 { - return ErrInvalidLengthProvider - } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } @@ -3377,11 +2827,8 @@ func skipProvider(dAtA []byte) (n int, err error) { break } } - if length < 0 { - return 0, ErrInvalidLengthProvider - } iNdEx += length - if iNdEx < 0 { + if length < 0 { return 0, ErrInvalidLengthProvider } return iNdEx, nil @@ -3412,9 +2859,6 @@ func skipProvider(dAtA []byte) (n int, err error) { return 0, err } iNdEx = start + next - if iNdEx < 0 { - return 0, ErrInvalidLengthProvider - } } return iNdEx, nil case 4: @@ -3433,3 +2877,47 @@ var ( ErrInvalidLengthProvider = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowProvider = fmt.Errorf("proto: integer overflow") ) + +func init() { + proto.RegisterFile("agent/connect/ca/plugin/provider.proto", fileDescriptor_provider_8ff2d2670790989c) +} + +var fileDescriptor_provider_8ff2d2670790989c = []byte{ + // 566 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x54, 0xdf, 0x6e, 0xd3, 0x3e, + 0x18, 0xfd, 0xa5, 0xfb, 0xad, 0x5d, 0xbf, 0x15, 0xad, 0xf2, 0xa6, 0xb5, 0x14, 0x68, 0xab, 0x08, + 0xad, 0x45, 0x40, 0x23, 0x28, 0x68, 0x12, 0x57, 0x94, 0x68, 0x4c, 0x13, 0x37, 0x23, 0x15, 0x37, + 0x5c, 0x50, 0xa5, 0xae, 0x49, 0x2d, 0x35, 0x71, 0xb0, 0x9d, 0x49, 0xbc, 0x09, 0x6f, 0x04, 0x97, + 0x3c, 0x02, 0x2a, 0x2f, 0x82, 0x9c, 0x26, 0x59, 0x92, 0xa6, 0xcb, 0x5d, 0xfc, 0xe5, 0x9c, 0xf3, + 0xfd, 0x3b, 0x36, 0x9c, 0xd9, 0x0e, 0xf1, 0xa4, 0x81, 0x99, 0xe7, 0x11, 0x2c, 0x0d, 0x6c, 0x1b, + 0xfe, 0x2a, 0x70, 0xa8, 0x67, 0xf8, 0x9c, 0xdd, 0xd0, 0x05, 0xe1, 0x23, 0x9f, 0x33, 0xc9, 0x50, + 0x75, 0x13, 0xd6, 0xe7, 0xd0, 0x34, 0x99, 0xf7, 0x95, 0x3a, 0x01, 0x27, 0x16, 0xf9, 0x16, 0x10, + 0x21, 0xd1, 0x23, 0x00, 0xbc, 0x0a, 0x84, 0x24, 0x7c, 0x46, 0x17, 0x6d, 0xad, 0xaf, 0x0d, 0xeb, + 0x56, 0x3d, 0x8a, 0x5c, 0x2d, 0x50, 0x0b, 0x6a, 0x54, 0xcc, 0x38, 0x63, 0xb2, 0x5d, 0xe9, 0x6b, + 0xc3, 0x03, 0xab, 0x4a, 0x85, 0xc5, 0x98, 0x44, 0xa7, 0x50, 0xc5, 0xa1, 0x56, 0x7b, 0xaf, 0xaf, + 0x0d, 0x1b, 0x56, 0x74, 0xd2, 0xbf, 0xc0, 0xe9, 0x94, 0xc8, 0x2b, 0x4f, 0x12, 0xee, 0x92, 0x05, + 0xb5, 0x65, 0x92, 0xe9, 0x09, 0x34, 0x69, 0x2a, 0x3c, 0xf3, 0x89, 0x1b, 0xe5, 0x3b, 0x4a, 0xc7, + 0xaf, 0x89, 0x8b, 0xee, 0xc3, 0x81, 0x4a, 0x19, 0x42, 0x2a, 0x21, 0xa4, 0xa6, 0xce, 0xd7, 0xc4, + 0xd5, 0x7b, 0x70, 0x38, 0xa5, 0x8e, 0x17, 0x8b, 0x36, 0x61, 0x0f, 0x0b, 0x1e, 0xea, 0x34, 0x2c, + 0xf5, 0xa9, 0x3f, 0x85, 0x96, 0x02, 0x14, 0x55, 0xb0, 0x0d, 0x3e, 0x03, 0x64, 0x72, 0x26, 0x84, + 0x62, 0x98, 0x93, 0x34, 0x8e, 0xcb, 0x04, 0xc7, 0xa5, 0xfe, 0x1c, 0xd0, 0x04, 0x4b, 0x7a, 0x43, + 0x54, 0xef, 0x16, 0x11, 0x3e, 0xf3, 0x04, 0x51, 0xc3, 0xc1, 0x5c, 0xa6, 0x1a, 0xa9, 0x62, 0x1e, + 0x16, 0xf9, 0x06, 0x7a, 0x97, 0xc4, 0x23, 0xdc, 0x96, 0x24, 0x5d, 0x87, 0x39, 0xb5, 0x32, 0x5c, + 0xc1, 0x33, 0x5c, 0xc1, 0x15, 0xf7, 0x35, 0x74, 0x36, 0xa9, 0xb2, 0x1d, 0x94, 0xa5, 0x3c, 0x87, + 0x87, 0x45, 0x29, 0xcb, 0x89, 0x03, 0x68, 0x6c, 0x06, 0x5a, 0x06, 0x1c, 0x43, 0x7b, 0x7b, 0xb0, + 0x65, 0xa4, 0x11, 0x1c, 0x67, 0x06, 0x5c, 0x86, 0xaf, 0xc1, 0xfe, 0x85, 0xeb, 0xcb, 0xef, 0x2f, + 0x7f, 0xee, 0x43, 0xc5, 0x9c, 0xa0, 0x57, 0x50, 0x4f, 0x2c, 0x8b, 0xda, 0xa3, 0x8d, 0x91, 0x47, + 0x79, 0x17, 0x77, 0xee, 0xc5, 0x7f, 0x42, 0x32, 0x7a, 0x06, 0x8d, 0x78, 0x18, 0xa1, 0x59, 0xb3, + 0xbf, 0xf3, 0xe8, 0x73, 0x80, 0xdb, 0xe5, 0xe6, 0xb1, 0x9d, 0xf8, 0x58, 0xb0, 0xff, 0x8f, 0xd0, + 0xda, 0xb1, 0xe6, 0xbc, 0xca, 0x20, 0x3e, 0x96, 0xd9, 0xe2, 0x2d, 0x1c, 0xe5, 0xae, 0x0f, 0xea, + 0xc6, 0xdc, 0xe2, 0x7b, 0x95, 0xef, 0xe6, 0x32, 0xb6, 0x6a, 0x46, 0x24, 0x57, 0x8f, 0x9e, 0xed, + 0xaa, 0x70, 0xa7, 0x1f, 0xe0, 0xa4, 0xa8, 0xda, 0xbc, 0xd4, 0xe3, 0xbb, 0x5a, 0x4b, 0xc4, 0x5e, + 0xc0, 0xff, 0xca, 0x02, 0xe8, 0x38, 0x69, 0xe6, 0xf6, 0x12, 0x77, 0x4e, 0xb2, 0xc1, 0x88, 0xf2, + 0x09, 0x9a, 0x79, 0xbf, 0xa1, 0x5e, 0x1a, 0x59, 0x34, 0x8c, 0xfe, 0x6e, 0x40, 0x24, 0xfb, 0x1e, + 0x0e, 0x53, 0x8e, 0x44, 0xc9, 0x7e, 0xb7, 0xdf, 0x81, 0xce, 0x83, 0xc2, 0x7f, 0x91, 0xce, 0x00, + 0x6a, 0xe6, 0x8a, 0xd8, 0x5e, 0xe0, 0xdf, 0x6d, 0xaf, 0x77, 0x17, 0xbf, 0xd6, 0x5d, 0xed, 0xf7, + 0xba, 0xab, 0xfd, 0x59, 0x77, 0xb5, 0x1f, 0x7f, 0xbb, 0xff, 0x7d, 0x1e, 0x3b, 0x54, 0x2e, 0x83, + 0xf9, 0x08, 0x33, 0xd7, 0x58, 0xda, 0x62, 0x49, 0x31, 0xe3, 0xbe, 0x7a, 0xc6, 0x45, 0xb0, 0x32, + 0x76, 0xbc, 0xe9, 0xf3, 0x6a, 0xf8, 0x96, 0x8f, 0xff, 0x05, 0x00, 0x00, 0xff, 0xff, 0x7b, 0x20, + 0xb4, 0xe4, 0xf5, 0x05, 0x00, 0x00, +} diff --git a/agent/connect/ca/plugin/provider.proto b/agent/connect/ca/plugin/provider.proto index d1a41ff45..6ca9cf88f 100644 --- a/agent/connect/ca/plugin/provider.proto +++ b/agent/connect/ca/plugin/provider.proto @@ -14,8 +14,6 @@ option go_package = "github.com/hashicorp/consul/agent/connect/ca/plugin"; package plugin; -import "google/protobuf/duration.proto"; - service CA { rpc Configure(ConfigureRequest) returns (Empty); rpc GenerateRoot(Empty) returns (Empty); @@ -28,8 +26,6 @@ service CA { rpc SignIntermediate(SignIntermediateRequest) returns (SignIntermediateResponse); rpc CrossSignCA(CrossSignCARequest) returns (CrossSignCAResponse); rpc Cleanup(Empty) returns (Empty); - rpc SupportsCrossSigning(Empty) returns (SupportsCrossSigningResponse); - rpc MinLifetime(Empty) returns (MinLifetimeResponse); } message ConfigureRequest { @@ -83,14 +79,6 @@ message CrossSignCAResponse { string crt_pem = 1; } -message SupportsCrossSigningResponse { - bool supports_cross_signing = 1; -} - -message MinLifetimeResponse { - google.protobuf.Duration min_lifetime = 1; -} - // Protobufs doesn't allow no req/resp so in the cases where there are // no arguments we use the Empty message. message Empty {} diff --git a/agent/connect/ca/plugin/transport_grpc.go b/agent/connect/ca/plugin/transport_grpc.go index 384a87887..cb21e559c 100644 --- a/agent/connect/ca/plugin/transport_grpc.go +++ b/agent/connect/ca/plugin/transport_grpc.go @@ -4,12 +4,9 @@ import ( "context" "crypto/x509" "encoding/json" - "time" - - "github.com/gogo/protobuf/types" - "google.golang.org/grpc" "github.com/hashicorp/consul/agent/connect/ca" + "google.golang.org/grpc" ) // providerPluginGRPCServer implements the CAServer interface for gRPC. @@ -84,15 +81,6 @@ func (p *providerPluginGRPCServer) CrossSignCA(_ context.Context, req *CrossSign return &CrossSignCAResponse{CrtPem: crtPEM}, err } -func (p *providerPluginGRPCServer) SupportsCrossSigning(context.Context, *Empty) (*SupportsCrossSigningResponse, error) { - s := p.impl.SupportsCrossSigning() - return &SupportsCrossSigningResponse{SupportsCrossSigning: s}, nil -} - -func (p *providerPluginGRPCServer) MinLifetime(context.Context, *Empty) (*MinLifetimeResponse, error) { - return &MinLifetimeResponse{MinLifetime: types.DurationProto(p.impl.MinLifetime())}, nil -} - func (p *providerPluginGRPCServer) Cleanup(context.Context, *Empty) (*Empty, error) { return &Empty{}, p.impl.Cleanup() } @@ -204,17 +192,6 @@ func (p *providerPluginGRPCClient) CrossSignCA(crt *x509.Certificate) (string, e return resp.CrtPem, nil } -func (p *providerPluginGRPCClient) SupportsCrossSigning() bool { - resp, _ := p.client.SupportsCrossSigning(p.doneCtx, &Empty{}) - return resp.SupportsCrossSigning -} - -func (p *providerPluginGRPCClient) MinLifetime() time.Duration { - resp, _ := p.client.MinLifetime(p.doneCtx, &Empty{}) - min, _ := types.DurationFromProto(resp.MinLifetime) - return min -} - func (p *providerPluginGRPCClient) Cleanup() error { _, err := p.client.Cleanup(p.doneCtx, &Empty{}) return p.err(err) diff --git a/agent/connect/ca/plugin/transport_netrpc.go b/agent/connect/ca/plugin/transport_netrpc.go index edd40f173..8186e1d00 100644 --- a/agent/connect/ca/plugin/transport_netrpc.go +++ b/agent/connect/ca/plugin/transport_netrpc.go @@ -3,9 +3,6 @@ package plugin import ( "crypto/x509" "net/rpc" - "time" - - "github.com/gogo/protobuf/types" "github.com/hashicorp/consul/agent/connect/ca" ) @@ -83,17 +80,6 @@ func (p *providerPluginRPCServer) CrossSignCA(args *CrossSignCARequest, resp *Cr return err } -func (p *providerPluginRPCServer) SupportsCrossSigning(_ struct{}, resp *SupportsCrossSigningResponse) error { - s := p.impl.SupportsCrossSigning() - resp.SupportsCrossSigning = s - return nil -} - -func (p *providerPluginRPCServer) MinLifetime(_ struct{}, resp *MinLifetimeResponse) error { - resp.MinLifetime = types.DurationProto(p.impl.MinLifetime()) - return nil -} - func (p *providerPluginRPCServer) Cleanup(struct{}, *struct{}) error { return p.impl.Cleanup() } @@ -177,19 +163,6 @@ func (p *providerPluginRPCClient) CrossSignCA(crt *x509.Certificate) (string, er return resp.CrtPem, err } -func (p *providerPluginRPCClient) SupportsCrossSigning() bool { - var resp SupportsCrossSigningResponse - _ = p.client.Call("Plugin.SupportsCrossSigning", struct{}{}, &resp) - return resp.SupportsCrossSigning -} - -func (p *providerPluginRPCClient) MinLifetime() time.Duration { - var resp MinLifetimeResponse - _ = p.client.Call("Plugin.MinLifetime", struct{}{}, &resp) - min, _ := types.DurationFromProto(resp.MinLifetime) - return min -} - func (p *providerPluginRPCClient) Cleanup() error { return p.client.Call("Plugin.Cleanup", struct{}{}, &struct{}{}) } diff --git a/agent/connect/ca/provider.go b/agent/connect/ca/provider.go index 4fcb3f98b..1a89d6492 100644 --- a/agent/connect/ca/provider.go +++ b/agent/connect/ca/provider.go @@ -2,21 +2,10 @@ package ca import ( "crypto/x509" - "log" - "time" ) //go:generate mockery -name Provider -inpkg -// NeedsLogger is an interface that allows Consul to pass a configured -// logger into any component that needs one. -type NeedsLogger interface { - // SetLogger tells the provider to use the specified logger. - // This is called immediately after instantiating - // the provider, so that the provider can log startup messages etc. - SetLogger(l *log.Logger) -} - // Provider is the interface for Consul to interact with // an external CA that provides leaf certificate signing for // given SpiffeIDServices. @@ -80,14 +69,6 @@ type Provider interface { // returned as a PEM formatted string. CrossSignCA(*x509.Certificate) (string, error) - // SupportsCrossSigning indicates whether the provider supports cross-signing - // other CA certs via CrossSignCA(). - SupportsCrossSigning() bool - - // MinLifetime returns the minimum TTL allowed by the provider for certificates - // it issues. - MinLifetime() time.Duration - // Cleanup performs any necessary cleanup that should happen when the provider // is shut down permanently, such as removing a temporary PKI backend in Vault // created for an intermediate CA. diff --git a/agent/connect/ca/provider_aws.go b/agent/connect/ca/provider_aws.go deleted file mode 100644 index ac87cc506..000000000 --- a/agent/connect/ca/provider_aws.go +++ /dev/null @@ -1,327 +0,0 @@ -package ca - -import ( - "bytes" - "crypto/x509" - "encoding/pem" - "fmt" - "log" - "strings" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/aws/session" - "github.com/aws/aws-sdk-go/service/acmpca" - "github.com/mitchellh/mapstructure" - - "github.com/hashicorp/consul/agent/connect" - "github.com/hashicorp/consul/agent/structs" -) - -type AWSProvider struct { - config *structs.AWSCAProviderConfig - session *session.Session - client *acmpca.ACMPCA - isRoot bool - clusterId string - logger *log.Logger - rootPCA *AmazonPCA - subPCA *AmazonPCA - sleepTime time.Duration -} - -func (v *AWSProvider) SetLogger(l *log.Logger) { - v.logger = l -} - -func (v *AWSProvider) Configure(clusterId string, isRoot bool, rawConfig map[string]interface{}) error { - config, err := ParseAWSCAConfig(rawConfig) - if err != nil { - return err - } - - sleepTime, err := time.ParseDuration(config.SleepTime) - if err != nil { - return fmt.Errorf("invalid sleep time specified: %s", err) - } - if sleepTime.Seconds() < 1 { - return fmt.Errorf("invalid sleep time specified: must be at least 1s") - } - - creds := credentials.NewStaticCredentials(config.AccessKeyId, config.SecretAccessKey, "") - awsSession, err := session.NewSession(&aws.Config{ - Region: aws.String(config.Region), - Credentials: creds, - }) - if err != nil { - return err - } - - v.config = config - v.session = awsSession - v.isRoot = isRoot - v.clusterId = clusterId - v.client = acmpca.New(awsSession) - v.sleepTime = sleepTime - - return nil -} - -func (v *AWSProvider) loadFindOrCreate(arn string, pcaType string) (*AmazonPCA, error) { - if arn != "" { - return LoadAmazonPCA(v.client, v.config, arn, pcaType, v.clusterId, - v.config.KeyAlgorithm, v.config.SigningAlgorithm, v.logger) - } else { - pca, err := FindAmazonPCA(v.client, v.config, pcaType, v.clusterId, - v.config.KeyAlgorithm, v.config.SigningAlgorithm, v.logger) - if err != nil { - return nil, err - } - if pca == nil { - pca, err = CreateAmazonPCA(v.client, v.config, pcaType, v.clusterId, - v.config.KeyAlgorithm, v.config.SigningAlgorithm, v.logger) - if err != nil { - return nil, err - } - } - return pca, nil - } -} - -func (v *AWSProvider) GenerateRoot() error { - if !v.isRoot { - return fmt.Errorf("provider is not the root certificate authority") - } - - if v.rootPCA != nil { - return nil // root PCA has already been created - } - - rootPCA, err := v.loadFindOrCreate(v.config.RootARN, acmpca.CertificateAuthorityTypeRoot) - if err != nil { - return err - } - - v.rootPCA = rootPCA - return v.rootPCA.Generate(v.rootPCA) -} - -func (v *AWSProvider) ensureIntermediate() error { - if v.subPCA != nil { - return nil - } - - subPCA, err := v.loadFindOrCreate(v.config.IntermediateARN, acmpca.CertificateAuthorityTypeSubordinate) - if err != nil { - return err - } - - v.subPCA = subPCA - return v.subPCA.Generate(v.rootPCA) -} - -func (v *AWSProvider) ActiveRoot() (string, error) { - return v.rootPCA.Certificate(), nil -} - -func (v *AWSProvider) GenerateIntermediateCSR() (string, error) { - if v.isRoot { - return "", fmt.Errorf("provider is the root certificate authority, " + - "cannot generate an intermediate CSR") - } - - if err := v.ensureIntermediate(); err != nil { - return "", err - } - - v.logger.Print("[INFO] requesting CSR for new intermediate CA cert") - return v.subPCA.GetCSR() -} - -func (v *AWSProvider) SetIntermediate(intermediatePEM string, rootPEM string) error { - if err := v.ensureIntermediate(); err != nil { - return err - } - return v.subPCA.SetCert(intermediatePEM, rootPEM) -} - -func (v *AWSProvider) ActiveIntermediate() (string, error) { - if err := v.ensureIntermediate(); err != nil { - return "", err - } - return v.subPCA.Certificate(), nil -} - -func (v *AWSProvider) GenerateIntermediate() (string, error) { - if err := v.ensureIntermediate(); err != nil { - return "", err - } - if err := v.subPCA.Generate(v.rootPCA); err != nil { - return "", err - } - return v.subPCA.Certificate(), nil -} - -func (v *AWSProvider) Sign(csr *x509.CertificateRequest) (string, error) { - - if err := v.ensureIntermediate(); err != nil { - return "", err - } - - var pemBuf bytes.Buffer - if err := pem.Encode(&pemBuf, &pem.Block{Type: "CERTIFICATE REQUEST", Bytes: csr.Raw}); err != nil { - return "", fmt.Errorf("error encoding CSR into PEM format: %s", err) - } - - leafPEM, err := v.subPCA.SignLeaf(pemBuf.String(), v.config.LeafCertTTL) - - return leafPEM, err -} - -func (v *AWSProvider) SignIntermediate(csr *x509.CertificateRequest) (string, error) { - - spiffeID := connect.SpiffeIDSigning{ClusterID: v.clusterId, Domain: "consul"} - - if len(csr.URIs) < 1 { - return "", fmt.Errorf("intermediate does not contain a trust domain SAN") - } - - if csr.URIs[0].String() != spiffeID.URI().String() { - return "", fmt.Errorf("attempt to sign intermediate from a different trust domain: "+ - "mine='%s' theirs='%s'", spiffeID.URI().String(), csr.URIs[0].String()) - } - - var buf bytes.Buffer - if err := pem.Encode(&buf, &pem.Block{Type: "CERTIFICATE REQUEST", Bytes: csr.Raw}); err != nil { - return "", fmt.Errorf("error encoding private key: %s", err) - } - - return v.rootPCA.SignIntermediate(buf.String()) -} - -// I'm not sure this can actually be implemented. PCA cannot cross-sign a cert, it can only -// sign a CSR, and we cannot generate a CSR from another provider's certificate without its -// private key. -func (v *AWSProvider) CrossSignCA(newCA *x509.Certificate) (string, error) { - return "", fmt.Errorf("not implemented in AWS PCA provider") -} - -func (v *AWSProvider) Cleanup() error { - if v.config.DeleteOnExit { - if v.subPCA != nil { - if err := v.subPCA.Disable(); err != nil { - v.logger.Printf("[WARN] error disabling subordinate PCA: %s", err.Error()) - } - if err := v.subPCA.Delete(); err != nil { - v.logger.Printf("[WARN] error deleting subordinate PCA: %s", err.Error()) - } - v.subPCA = nil - } - if v.rootPCA != nil { - if err := v.rootPCA.Disable(); err != nil { - v.logger.Printf("[WARN] error disabling root PCA: %s", err.Error()) - } - if err := v.rootPCA.Delete(); err != nil { - v.logger.Printf("[WARN] error deleting root PCA: %s", err.Error()) - } - v.rootPCA = nil - } - } - return nil -} - -func (v *AWSProvider) SupportsCrossSigning() bool { - return false -} - -func (v *AWSProvider) MinLifetime() time.Duration { - return 24 * time.Hour -} - -func ParseAWSCAConfig(raw map[string]interface{}) (*structs.AWSCAProviderConfig, error) { - config := structs.AWSCAProviderConfig{ - CommonCAProviderConfig: defaultCommonConfig(), - SleepTime: "5s", - } - - decodeConf := &mapstructure.DecoderConfig{ - DecodeHook: structs.ParseDurationFunc(), - Result: &config, - WeaklyTypedInput: true, - } - - decoder, err := mapstructure.NewDecoder(decodeConf) - if err != nil { - return nil, err - } - - if err := decoder.Decode(raw); err != nil { - return nil, fmt.Errorf("error decoding config: %s", err) - } - - if config.AccessKeyId == "" { - return nil, fmt.Errorf("must provide the AWS access key ID") - } - - if config.SecretAccessKey == "" { - return nil, fmt.Errorf("must provide the AWS secret access key") - } - - if config.Region == "" { - return nil, fmt.Errorf("must provide the AWS region") - } - - if config.RootARN != "" { - if !IsValidARN(config.RootARN) { - return nil, fmt.Errorf("root PCA ARN is not in correct format") - } - } - - if config.IntermediateARN != "" { - if !IsValidARN(config.IntermediateARN) { - return nil, fmt.Errorf("intermediate PCA ARN is not in correct format") - } - } - - if config.KeyAlgorithm == "" { - config.KeyAlgorithm = acmpca.KeyAlgorithmEcPrime256v1 - } else { - config.KeyAlgorithm, err = ValidateEnum(config.KeyAlgorithm, - acmpca.KeyAlgorithmRsa2048, acmpca.KeyAlgorithmRsa4096, - acmpca.KeyAlgorithmEcPrime256v1, acmpca.KeyAlgorithmEcSecp384r1) - if err != nil { - return nil, fmt.Errorf("invalid key algorithm specified: %s", err) - } - } - - if config.SigningAlgorithm == "" { - config.SigningAlgorithm = acmpca.SigningAlgorithmSha256withecdsa - } else { - config.SigningAlgorithm, err = ValidateEnum(config.SigningAlgorithm, - acmpca.SigningAlgorithmSha256withrsa, acmpca.SigningAlgorithmSha384withrsa, - acmpca.SigningAlgorithmSha512withrsa, acmpca.SigningAlgorithmSha256withecdsa, - acmpca.SigningAlgorithmSha384withecdsa, acmpca.SigningAlgorithmSha512withecdsa) - if err != nil { - return nil, fmt.Errorf("invalid signing algorithm specified: %s", err) - } - } - - if err := config.CommonCAProviderConfig.Validate(); err != nil { - return nil, err - } - - return &config, nil -} - -func ValidateEnum(value string, choices ...string) (string, error) { - for _, choice := range choices { - if strings.ToLower(value) == strings.ToLower(choice) { - return choice, nil - } - } - - return "", fmt.Errorf("must be one of %s or %s", - strings.Join(choices[:len(choices)-1], ","), - choices[len(choices)-1]) -} diff --git a/agent/connect/ca/provider_aws_test.go b/agent/connect/ca/provider_aws_test.go deleted file mode 100644 index c9059934b..000000000 --- a/agent/connect/ca/provider_aws_test.go +++ /dev/null @@ -1,392 +0,0 @@ -package ca - -import ( - "crypto/x509" - "log" - "os" - "testing" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/aws/session" - "github.com/aws/aws-sdk-go/service/acmpca" - "github.com/stretchr/testify/require" - - "github.com/hashicorp/consul/agent/connect" - "github.com/hashicorp/consul/agent/structs" -) - -var awsAccessKeyId string -var awsSecretAccessKey string -var awsRegion string -var awsClient *acmpca.ACMPCA - -func init() { - awsAccessKeyId = os.Getenv("AWS_ACCESS_KEY_ID") - awsSecretAccessKey = os.Getenv("AWS_SECRET_ACCESS_KEY") - awsRegion = os.Getenv("AWS_REGION") - awsSession, _ := session.NewSession(&aws.Config{ - Region: aws.String(awsRegion), - Credentials: credentials.NewStaticCredentials(awsAccessKeyId, awsSecretAccessKey, ""), - }) - awsClient = acmpca.New(awsSession) -} - -func makeConfig() *structs.CAConfiguration { - return &structs.CAConfiguration{ - ClusterID: "asdf", - Provider: "aws", - Config: map[string]interface{}{ - "LeafCertTTL": "72h", - "Region": awsRegion, - "AccessKeyId": awsAccessKeyId, - "SecretAccessKey": awsSecretAccessKey, - "KeyAlgorithm": acmpca.KeyAlgorithmEcPrime256v1, - "SigningAlgorithm": acmpca.SigningAlgorithmSha256withecdsa, - }, - } -} - -func makeProvider(r *require.Assertions, config *structs.CAConfiguration) *AWSProvider { - logger := log.New(os.Stderr, "aws_pca", log.LstdFlags) - provider := &AWSProvider{logger: logger} - r.NoError(provider.Configure(config.ClusterID, true, config.Config)) - return provider -} - -func TestAWSProvider_Configure(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - r.Equal(conf.Config["AccessKeyId"], provider.config.AccessKeyId) - r.Equal(conf.Config["SecretAccessKey"], provider.config.SecretAccessKey) - r.Equal(conf.Config["Region"], provider.config.Region) -} - -func TestAWSProvider_ConfigureBadKeyAlgorithm(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - conf.Config["KeyAlgorithm"] = "foo" - provider := &AWSProvider{} - r.Error(provider.Configure(conf.ClusterID, true, conf.Config)) -} - -func TestAWSProvider_ConfigureBadSigningAlgorithm(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - conf.Config["SigningAlgorithm"] = "foo" - provider := &AWSProvider{} - r.Error(provider.Configure(conf.ClusterID, true, conf.Config)) -} - -func TestAWSProvider_ConfigureBadSleepTime(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - - conf.Config["SleepTime"] = "-5s" - provider := &AWSProvider{} - r.Error(provider.Configure(conf.ClusterID, true, conf.Config)) - - conf.Config["SleepTime"] = "5foo" - provider = &AWSProvider{} - r.Error(provider.Configure(conf.ClusterID, true, conf.Config)) -} - -func TestAWSProvider_ConfigureBadLeafTTL(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - conf.Config["LeafCertTTL"] = "-72h" - provider := &AWSProvider{} - r.Error(provider.Configure(conf.ClusterID, true, conf.Config)) -} - -func TestAWSProvider_GenerateRoot(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - r.NotEmpty(provider.rootPCA.arn) - - output, err := awsClient.DescribeCertificateAuthority(&acmpca.DescribeCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(provider.rootPCA.arn), - }) - r.NoError(err) - - ca := output.CertificateAuthority - caConf := ca.CertificateAuthorityConfiguration - r.Equal(acmpca.CertificateAuthorityStatusActive, *ca.Status) - r.Equal(acmpca.KeyAlgorithmEcPrime256v1, *caConf.KeyAlgorithm) - r.Equal(acmpca.SigningAlgorithmSha256withecdsa, *caConf.SigningAlgorithm) - r.Contains(*caConf.Subject.CommonName, conf.ClusterID) -} - -func TestAWSProvider_GenerateRootNotRoot(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - provider.isRoot = false - r.Error(provider.GenerateRoot()) -} - -func TestAWSProvider_Sign(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - cn := "foo" - pk, _, err := connect.GeneratePrivateKeyWithConfig("rsa", 2048) - r.NoError(err) - - serviceID := &connect.SpiffeIDService{ - Host: "11111111-2222-3333-4444-555555555555.consul", - Datacenter: "dc1", - Namespace: "default", - Service: "foo", - } - - csrText, err := connect.CreateCSR(cn, serviceID, pk) - r.NoError(err) - - csr, err := connect.ParseCSR(csrText) - r.NoError(err) - - leafText, err := provider.Sign(csr) - r.NoError(err) - - leaf, err := connect.ParseCert(leafText) - r.NoError(err) - - r.Equal(csr.Subject.CommonName, leaf.Subject.CommonName) - r.Equal(serviceID.URI().String(), leaf.URIs[0].String()) - r.True(leaf.NotBefore.Before(time.Now())) - r.True(leaf.NotAfter.After(time.Now())) -} - -func TestAWSProvider_GenerateIntermediateCSR(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - _, err := provider.GenerateIntermediateCSR() - r.Error(err) - - provider.isRoot = false - csrText, err := provider.GenerateIntermediateCSR() - - csr, err := connect.ParseCSR(csrText) - r.NoError(err) - - r.Contains(csr.Subject.CommonName, conf.ClusterID) - r.Equal(x509.ECDSA, csr.PublicKeyAlgorithm) - r.Equal(x509.ECDSAWithSHA256, csr.SignatureAlgorithm) -} - -func TestAWSProvider_ActiveRoot(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - rootText, err := provider.ActiveRoot() - r.NoError(err) - - root, err := connect.ParseCert(rootText) - r.NoError(err) - - r.Equal(x509.ECDSA, root.PublicKeyAlgorithm) - r.Equal(x509.ECDSAWithSHA256, root.SignatureAlgorithm) - r.True(root.NotBefore.Before(time.Now())) - r.True(root.NotAfter.After(time.Now())) - r.True(root.IsCA) -} - -func TestAWSProvider_GenerateIntermediate(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - interText, err := provider.GenerateIntermediate() - r.NoError(err) - - inter, err := connect.ParseCert(interText) - r.NoError(err) - - r.Contains(inter.Subject.CommonName, conf.ClusterID) - r.Equal(x509.ECDSA, inter.PublicKeyAlgorithm) - r.Equal(x509.ECDSAWithSHA256, inter.SignatureAlgorithm) - r.True(inter.NotBefore.Before(time.Now())) - r.True(inter.NotAfter.After(time.Now())) - r.True(inter.IsCA) - r.True(inter.MaxPathLenZero) -} - -func TestAWSProvider_ActiveIntermediate(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - interText, err := provider.ActiveIntermediate() - r.NoError(err) - - inter, err := connect.ParseCert(interText) - r.NoError(err) - - r.Contains(inter.Subject.CommonName, conf.ClusterID) - r.Equal(x509.ECDSA, inter.PublicKeyAlgorithm) - r.Equal(x509.ECDSAWithSHA256, inter.SignatureAlgorithm) - r.True(inter.NotBefore.Before(time.Now())) - r.True(inter.NotAfter.After(time.Now())) - r.True(inter.IsCA) - r.True(inter.MaxPathLenZero) -} - -func TestAWSProvider_SignIntermediate(t *testing.T) { - t.Parallel() - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - - conf2 := testConsulCAConfig() - delegate2 := newMockDelegate(t, conf2) - provider2 := &ConsulProvider{Delegate: delegate2} - r.NoError(provider2.Configure(conf2.ClusterID, false, conf2.Config)) - - testSignIntermediateCrossDC(t, provider, provider2) -} - -func TestAWSProvider_Cleanup(t *testing.T) { - // THIS TEST CANNOT BE RUN IN PARALLEL. - // It disables and deletes the PCA, which will cause other tests to fail if they are running - // at the same time. - - if awsAccessKeyId == "" || awsSecretAccessKey == "" || awsRegion == "" { - t.Skip("skipping test due to missing AWS credentials") - } - - r := require.New(t) - conf := makeConfig() - conf.Config["DeleteOnExit"] = true - provider := makeProvider(r, conf) - - r.NoError(provider.GenerateRoot()) - _, err := provider.GenerateIntermediate() - r.NoError(err) - - rootPCA := provider.rootPCA - subPCA := provider.subPCA - r.NoError(provider.Cleanup()) - - output, err := awsClient.DescribeCertificateAuthority(&acmpca.DescribeCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(rootPCA.arn), - }) - r.NoError(err) - - ca := output.CertificateAuthority - r.Equal(acmpca.CertificateAuthorityStatusDeleted, *ca.Status) - r.Equal((*AmazonPCA)(nil), provider.rootPCA) - - r.NoError(rootPCA.Undelete()) - r.NoError(rootPCA.Enable()) - - output, err = awsClient.DescribeCertificateAuthority(&acmpca.DescribeCertificateAuthorityInput{ - CertificateAuthorityArn: aws.String(subPCA.arn), - }) - r.NoError(err) - - ca = output.CertificateAuthority - r.Equal(acmpca.CertificateAuthorityStatusDeleted, *ca.Status) - r.Equal((*AmazonPCA)(nil), provider.subPCA) - - r.NoError(subPCA.Undelete()) - r.NoError(subPCA.Enable()) -} diff --git a/agent/connect/ca/provider_consul.go b/agent/connect/ca/provider_consul.go index 8960db422..1b0d10d48 100644 --- a/agent/connect/ca/provider_consul.go +++ b/agent/connect/ca/provider_consul.go @@ -658,11 +658,3 @@ func (c *ConsulProvider) generateCA(privateKey string, sn uint64) (string, error return buf.String(), nil } - -func (c *ConsulProvider) SupportsCrossSigning() bool { - return true -} - -func (c *ConsulProvider) MinLifetime() time.Duration { - return 1 * time.Hour -} diff --git a/agent/connect/ca/provider_vault.go b/agent/connect/ca/provider_vault.go index 6cedc1065..f1fef4706 100644 --- a/agent/connect/ca/provider_vault.go +++ b/agent/connect/ca/provider_vault.go @@ -8,7 +8,6 @@ import ( "io/ioutil" "net/http" "strings" - "time" "github.com/hashicorp/consul/agent/connect" "github.com/hashicorp/consul/agent/structs" @@ -377,14 +376,6 @@ func (v *VaultProvider) Cleanup() error { return v.client.Sys().Unmount(v.config.IntermediatePKIPath) } -func (v *VaultProvider) SupportsCrossSigning() bool { - return true -} - -func (v *VaultProvider) MinLifetime() time.Duration { - return 1 * time.Hour -} - func ParseVaultCAConfig(raw map[string]interface{}) (*structs.VaultCAProviderConfig, error) { config := structs.VaultCAProviderConfig{ CommonCAProviderConfig: defaultCommonConfig(), diff --git a/agent/connect/csr.go b/agent/connect/csr.go index bea3cac3f..61a73ed33 100644 --- a/agent/connect/csr.go +++ b/agent/connect/csr.go @@ -3,7 +3,6 @@ package connect import ( "bytes" "crypto" - "crypto/ecdsa" "crypto/rand" "crypto/x509" "crypto/x509/pkix" @@ -14,21 +13,10 @@ import ( // CreateCSR returns a CSR to sign the given service along with the PEM-encoded // private key for this certificate. -func CreateCSR(commonName string, uri CertURI, privateKey crypto.Signer, - extensions ...pkix.Extension) (string, error) { - - signAlgo := x509.SHA256WithRSA - _, ok := privateKey.(*ecdsa.PrivateKey) - if ok { - signAlgo = x509.ECDSAWithSHA256 - } - +func CreateCSR(uri CertURI, privateKey crypto.Signer, extensions ...pkix.Extension) (string, error) { template := &x509.CertificateRequest{ - Subject: pkix.Name{ - CommonName: commonName, - }, URIs: []*url.URL{uri.URI()}, - SignatureAlgorithm: signAlgo, + SignatureAlgorithm: x509.ECDSAWithSHA256, ExtraExtensions: extensions, } @@ -55,7 +43,7 @@ func CreateCACSR(uri CertURI, privateKey crypto.Signer) (string, error) { return "", err } - return CreateCSR("Consul CA", uri, privateKey, ext) + return CreateCSR(uri, privateKey, ext) } // CreateCAExtension creates a pkix.Extension for the x509 Basic Constraints diff --git a/agent/consul/auto_encrypt.go b/agent/consul/auto_encrypt.go index 63f5bf002..6cc87154b 100644 --- a/agent/consul/auto_encrypt.go +++ b/agent/consul/auto_encrypt.go @@ -59,7 +59,7 @@ func (c *Client) RequestAutoEncryptCerts(servers []string, defaultPort int, toke } // Create a CSR. - csr, err := connect.CreateCSR("Consul RPC", id, pk) + csr, err := connect.CreateCSR(id, pk) if err != nil { return errFn(err) } diff --git a/agent/consul/auto_encrypt_endpoint_test.go b/agent/consul/auto_encrypt_endpoint_test.go index 9bbc77f2c..cc260b515 100644 --- a/agent/consul/auto_encrypt_endpoint_test.go +++ b/agent/consul/auto_encrypt_endpoint_test.go @@ -75,7 +75,7 @@ func TestAutoEncryptSign(t *testing.T) { require.NoError(t, err, info) // Create a CSR. - csr, err := connect.CreateCSR(info, id, pk) + csr, err := connect.CreateCSR(id, pk) require.NoError(t, err, info) require.NotEmpty(t, csr, info) args := &structs.CASignRequest{ diff --git a/agent/consul/connect_ca_endpoint.go b/agent/consul/connect_ca_endpoint.go index b7914c029..980f9351b 100644 --- a/agent/consul/connect_ca_endpoint.go +++ b/agent/consul/connect_ca_endpoint.go @@ -168,16 +168,6 @@ func (s *ConnectCA) ConfigurationSet( return nil } - // Have the old provider cross-sign the new intermediate - oldProvider, _ := s.srv.getCAProvider() - if oldProvider == nil { - return fmt.Errorf("internal error: CA provider is nil") - } - - if !oldProvider.SupportsCrossSigning() { - return fmt.Errorf("error: current CA does not support cross-signing") - } - // Create a new instance of the provider described by the config // and get the current active root CA. This acts as a good validation // of the config and makes sure the provider is functioning correctly @@ -247,6 +237,11 @@ func (s *ConnectCA) ConfigurationSet( return err } + // Have the old provider cross-sign the new intermediate + oldProvider, _ := s.srv.getCAProvider() + if oldProvider == nil { + return fmt.Errorf("internal error: CA provider is nil") + } xcCert, err := oldProvider.CrossSignCA(newRoot) if err != nil { return err diff --git a/agent/structs/connect_ca.go b/agent/structs/connect_ca.go index d3b144570..2e47162bd 100644 --- a/agent/structs/connect_ca.go +++ b/agent/structs/connect_ca.go @@ -112,53 +112,6 @@ type CARoot struct { // CARoots is a list of CARoot structures. type CARoots []*CARoot -// CAIntermediate represents an intermediate CA certificate that is trusted and used -// to sign leaf certificates. -type CAIntermediate struct { - // ID is a globally unique ID (UUID) representing this CA root. - ID string - - // Name is a human-friendly name for this CA root. This value is - // opaque to Consul and is not used for anything internally. - Name string - - // SerialNumber is the x509 serial number of the certificate. - SerialNumber uint64 - - // SigningKeyID is the ID of the public key that corresponds to the private - // key used to sign the certificate. Is is the HexString format of the raw - // AuthorityKeyID bytes. - SigningKeyID string - - // ExternalTrustDomain is the trust domain this root was generated under. It - // is usually empty implying "the current cluster trust-domain". It is set - // only in the case that a cluster changes trust domain and then all old roots - // that are still trusted have the old trust domain set here. - // - // We currently DON'T validate these trust domains explicitly anywhere, see - // IndexedRoots.TrustDomain doc. We retain this information for debugging and - // future flexibility. - ExternalTrustDomain string - - // Time validity bounds. - NotBefore time.Time - NotAfter time.Time - - // IntermediateCert is the PEM-encoded public certificate. - IntermediateCert string - - // Active is true if this is the current active CA. This must only - // be true for exactly one CA. For any method that modifies roots in the - // state store, tests should be written to verify that multiple roots - // cannot be active. - Active bool - - // RotatedOutAt is the time at which this CA was removed from the state. - // This will only be set on roots that have been rotated out from being the - // active root. - RotatedOutAt time.Time `json:"-"` -} - // CASignRequest is the request for signing a service certificate. type CASignRequest struct { // Datacenter is the target for this request. @@ -254,7 +207,6 @@ func (q *CARequest) RequestDatacenter() string { const ( ConsulCAProvider = "consul" VaultCAProvider = "vault" - AWSCAProvider = "aws" ) // CAConfiguration is the configuration for the current CA plugin. @@ -397,20 +349,6 @@ type VaultCAProviderConfig struct { TLSSkipVerify bool } -type AWSCAProviderConfig struct { - CommonCAProviderConfig `mapstructure:",squash"` - - AccessKeyId string - SecretAccessKey string - Region string - SleepTime string - RootARN string - IntermediateARN string - KeyAlgorithm string - SigningAlgorithm string - DeleteOnExit bool -} - // CALeafOp is the operation for a request related to leaf certificates. type CALeafOp string diff --git a/go.mod b/go.mod index 2db7780a4..cd93f3339 100644 --- a/go.mod +++ b/go.mod @@ -20,7 +20,6 @@ require ( github.com/armon/go-metrics v0.0.0-20190430140413-ec5e00d3c878 github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310 github.com/asaskevich/govalidator v0.0.0-20180319081651-7d2e70ef918f // indirect - github.com/aws/aws-sdk-go v1.21.1 github.com/bitly/go-hostpool v0.0.0-20171023180738-a3a6125de932 // indirect github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869 // indirect github.com/cenkalti/backoff v2.1.1+incompatible // indirect @@ -57,7 +56,7 @@ require ( github.com/hashicorp/go-msgpack v0.5.5 github.com/hashicorp/go-multierror v1.0.0 github.com/hashicorp/go-plugin v0.0.0-20180331002553-e8d22c780116 - github.com/hashicorp/go-raftchunking v0.6.2 + github.com/hashicorp/go-raftchunking v0.6.1 github.com/hashicorp/go-sockaddr v1.0.0 github.com/hashicorp/go-syslog v1.0.0 github.com/hashicorp/go-uuid v1.0.1 diff --git a/go.sum b/go.sum index d5dd738a2..0dce7ffa5 100644 --- a/go.sum +++ b/go.sum @@ -38,8 +38,6 @@ github.com/asaskevich/govalidator v0.0.0-20180319081651-7d2e70ef918f h1:/8NcnxL6 github.com/asaskevich/govalidator v0.0.0-20180319081651-7d2e70ef918f/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/aws/aws-sdk-go v1.15.24 h1:xLAdTA/ore6xdPAljzZRed7IGqQgC+nY+ERS5vaj4Ro= github.com/aws/aws-sdk-go v1.15.24/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZoCYDt7FT0= -github.com/aws/aws-sdk-go v1.21.1 h1:IOFDnCEDybcw4V8nbKqyyjBu+vpu7hFYSfZqNuogi7I= -github.com/aws/aws-sdk-go v1.21.1/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973 h1:xJ4a3vCFaGF/jqvzLMYoU8P317H5OQ+Via4RmuPwCS0= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= @@ -173,8 +171,6 @@ github.com/hashicorp/go-plugin v0.0.0-20180331002553-e8d22c780116 h1:Y4V/yReWjQo github.com/hashicorp/go-plugin v0.0.0-20180331002553-e8d22c780116/go.mod h1:JSqWYsict+jzcj0+xElxyrBQRPNoiWQuddnxArJ7XHQ= github.com/hashicorp/go-raftchunking v0.6.1 h1:moEnaG3gcwsWNyIBJoD5PCByE+Ewkqxh6N05CT+MbwA= github.com/hashicorp/go-raftchunking v0.6.1/go.mod h1:cGlg3JtDy7qy6c/3Bu660Mic1JF+7lWqIwCFSb08fX0= -github.com/hashicorp/go-raftchunking v0.6.2 h1:imj6CVkwXj6VzgXZQvzS+fSrkbFCzlJ2t00F3PacnuU= -github.com/hashicorp/go-raftchunking v0.6.2/go.mod h1:cGlg3JtDy7qy6c/3Bu660Mic1JF+7lWqIwCFSb08fX0= github.com/hashicorp/go-retryablehttp v0.5.3 h1:QlWt0KvWT0lq8MFppF9tsJGF+ynG7ztc2KIPhzRGk7s= github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= github.com/hashicorp/go-rootcerts v1.0.0 h1:Rqb66Oo1X/eSV1x66xbDccZjhJigjg0+e82kpwzSwCI= @@ -233,8 +229,6 @@ github.com/jefferai/jsonx v0.0.0-20160721235117-9cc31c3135ee h1:AQ/QmCk6x8ECPpf2 github.com/jefferai/jsonx v0.0.0-20160721235117-9cc31c3135ee/go.mod h1:N0t2vlmpe8nyZB5ouIbJQPDSR+mH6oe7xHB9VZHSUzM= github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8 h1:12VvqtR6Aowv3l/EQUlocDHW2Cp4G9WJVH7uyH8QFJE= github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= -github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af h1:pmfjZENx5imkbgOkpRUYLnmbU7UEFbjtDA2hxJ1ichM= -github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/joyent/triton-go v0.0.0-20180628001255-830d2b111e62 h1:JHCT6xuyPUrbbgAPE/3dqlvUKzRHMNuTBKKUb6OeR/k= github.com/joyent/triton-go v0.0.0-20180628001255-830d2b111e62/go.mod h1:U+RSyWxWd04xTqnuOQxnai7XGS2PrPY2cfGoDKtMHjA= github.com/json-iterator/go v1.1.5 h1:gL2yXlmiIo4+t+y32d4WGwOjKGYcGOuyrg46vadswDE= diff --git a/vendor/github.com/aws/aws-sdk-go/NOTICE.txt b/vendor/github.com/aws/aws-sdk-go/NOTICE.txt index 899129ecc..5f14d1162 100644 --- a/vendor/github.com/aws/aws-sdk-go/NOTICE.txt +++ b/vendor/github.com/aws/aws-sdk-go/NOTICE.txt @@ -1,3 +1,3 @@ AWS SDK for Go -Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. +Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. Copyright 2014-2015 Stripe, Inc. diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go b/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go index 99849c0e1..56fdfc2bf 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/awserr/error.go @@ -138,27 +138,8 @@ type RequestFailure interface { RequestID() string } -// NewRequestFailure returns a wrapped error with additional information for -// request status code, and service requestID. -// -// Should be used to wrap all request which involve service requests. Even if -// the request failed without a service response, but had an HTTP status code -// that may be meaningful. +// NewRequestFailure returns a new request error wrapper for the given Error +// provided. func NewRequestFailure(err Error, statusCode int, reqID string) RequestFailure { return newRequestError(err, statusCode, reqID) } - -// UnmarshalError provides the interface for the SDK failing to unmarshal data. -type UnmarshalError interface { - awsError - Bytes() []byte -} - -// NewUnmarshalError returns an initialized UnmarshalError error wrapper adding -// the bytes that fail to unmarshal to the error. -func NewUnmarshalError(err error, msg string, bytes []byte) UnmarshalError { - return &unmarshalError{ - awsError: New("UnmarshalError", msg, err), - bytes: bytes, - } -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go b/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go index a2c5817c4..0202a008f 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/awserr/types.go @@ -1,9 +1,6 @@ package awserr -import ( - "encoding/hex" - "fmt" -) +import "fmt" // SprintError returns a string of the formatted error code. // @@ -122,7 +119,6 @@ type requestError struct { awsError statusCode int requestID string - bytes []byte } // newRequestError returns a wrapped error with additional information for @@ -174,29 +170,6 @@ func (r requestError) OrigErrs() []error { return []error{r.OrigErr()} } -type unmarshalError struct { - awsError - bytes []byte -} - -// Error returns the string representation of the error. -// Satisfies the error interface. -func (e unmarshalError) Error() string { - extra := hex.Dump(e.bytes) - return SprintError(e.Code(), e.Message(), extra, e.OrigErr()) -} - -// String returns the string representation of the error. -// Alias for Error to satisfy the stringer interface. -func (e unmarshalError) String() string { - return e.Error() -} - -// Bytes returns the bytes that failed to unmarshal. -func (e unmarshalError) Bytes() []byte { - return e.bytes -} - // An error list that satisfies the golang interface type errorList []error diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go index 142a7a01c..59fa4a558 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/equal.go @@ -15,7 +15,7 @@ func DeepEqual(a, b interface{}) bool { rb := reflect.Indirect(reflect.ValueOf(b)) if raValid, rbValid := ra.IsValid(), rb.IsValid(); !raValid && !rbValid { - // If the elements are both nil, and of the same type they are equal + // If the elements are both nil, and of the same type the are equal // If they are of different types they are not equal return reflect.TypeOf(a) == reflect.TypeOf(b) } else if raValid != rbValid { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go index 645df2450..b6432f1a1 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go @@ -23,27 +23,28 @@ func stringValue(v reflect.Value, indent int, buf *bytes.Buffer) { case reflect.Struct: buf.WriteString("{\n") + names := []string{} for i := 0; i < v.Type().NumField(); i++ { - ft := v.Type().Field(i) - fv := v.Field(i) - - if ft.Name[0:1] == strings.ToLower(ft.Name[0:1]) { + name := v.Type().Field(i).Name + f := v.Field(i) + if name[0:1] == strings.ToLower(name[0:1]) { continue // ignore unexported fields } - if (fv.Kind() == reflect.Ptr || fv.Kind() == reflect.Slice) && fv.IsNil() { + if (f.Kind() == reflect.Ptr || f.Kind() == reflect.Slice) && f.IsNil() { continue // ignore unset fields } + names = append(names, name) + } + for i, n := range names { + val := v.FieldByName(n) buf.WriteString(strings.Repeat(" ", indent+2)) - buf.WriteString(ft.Name + ": ") + buf.WriteString(n + ": ") + stringValue(val, indent+2, buf) - if tag := ft.Tag.Get("sensitive"); tag == "true" { - buf.WriteString("") - } else { - stringValue(fv, indent+2, buf) + if i < len(names)-1 { + buf.WriteString(",\n") } - - buf.WriteString(",\n") } buf.WriteString("\n" + strings.Repeat(" ", indent) + "}") diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go b/vendor/github.com/aws/aws-sdk-go/aws/client/client.go index 709605384..212fe25e7 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/client/client.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/client/client.go @@ -18,7 +18,7 @@ type Config struct { // States that the signing name did not come from a modeled source but // was derived based on other data. Used by service client constructors - // to determine if the signin name can be overridden based on metadata the + // to determine if the signin name can be overriden based on metadata the // service has. SigningNameDerived bool } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go index 7b5e1276a..ce9fb896d 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/client/logger.go @@ -118,12 +118,6 @@ var LogHTTPResponseHandler = request.NamedHandler{ func logResponse(r *request.Request) { lw := &logWriter{r.Config.Logger, bytes.NewBuffer(nil)} - if r.HTTPResponse == nil { - lw.Logger.Log(fmt.Sprintf(logRespErrMsg, - r.ClientInfo.ServiceName, r.Operation.Name, "request's HTTPResponse is nil")) - return - } - logBody := r.Config.LogLevel.Matches(aws.LogDebugWithHTTPBody) if logBody { r.HTTPResponse.Body = &teeReaderCloser{ diff --git a/vendor/github.com/aws/aws-sdk-go/aws/config.go b/vendor/github.com/aws/aws-sdk-go/aws/config.go index 10634d173..5421b5d4e 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/config.go @@ -18,7 +18,7 @@ const UseServiceDefaultRetries = -1 type RequestRetryer interface{} // A Config provides service configuration for service clients. By default, -// all clients will use the defaults.DefaultConfig structure. +// all clients will use the defaults.DefaultConfig tructure. // // // Create Session with MaxRetry configuration to be shared by multiple // // service clients. @@ -45,8 +45,8 @@ type Config struct { // that overrides the default generated endpoint for a client. Set this // to `""` to use the default generated endpoint. // - // Note: You must still provide a `Region` value when specifying an - // endpoint for a client. + // @note You must still provide a `Region` value when specifying an + // endpoint for a client. Endpoint *string // The resolver to use for looking up endpoints for AWS service clients @@ -65,8 +65,8 @@ type Config struct { // noted. A full list of regions is found in the "Regions and Endpoints" // document. // - // See http://docs.aws.amazon.com/general/latest/gr/rande.html for AWS - // Regions and Endpoints. + // @see http://docs.aws.amazon.com/general/latest/gr/rande.html + // AWS Regions and Endpoints Region *string // Set this to `true` to disable SSL when sending requests. Defaults @@ -120,10 +120,9 @@ type Config struct { // will use virtual hosted bucket addressing when possible // (`http://BUCKET.s3.amazonaws.com/KEY`). // - // Note: This configuration option is specific to the Amazon S3 service. - // - // See http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html - // for Amazon S3: Virtual Hosting of Buckets + // @note This configuration option is specific to the Amazon S3 service. + // @see http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html + // Amazon S3: Virtual Hosting of Buckets S3ForcePathStyle *bool // Set this to `true` to disable the SDK adding the `Expect: 100-Continue` @@ -224,28 +223,6 @@ type Config struct { // Key: aws.String("//foo//bar//moo"), // }) DisableRestProtocolURICleaning *bool - - // EnableEndpointDiscovery will allow for endpoint discovery on operations that - // have the definition in its model. By default, endpoint discovery is off. - // - // Example: - // sess := session.Must(session.NewSession(&aws.Config{ - // EnableEndpointDiscovery: aws.Bool(true), - // })) - // - // svc := s3.New(sess) - // out, err := svc.GetObject(&s3.GetObjectInput { - // Bucket: aws.String("bucketname"), - // Key: aws.String("/foo/bar/moo"), - // }) - EnableEndpointDiscovery *bool - - // DisableEndpointHostPrefix will disable the SDK's behavior of prefixing - // request endpoint hosts with modeled information. - // - // Disabling this feature is useful when you want to use local endpoints - // for testing that do not support the modeled host prefix pattern. - DisableEndpointHostPrefix *bool } // NewConfig returns a new Config pointer that can be chained with builder @@ -400,19 +377,6 @@ func (c *Config) WithSleepDelay(fn func(time.Duration)) *Config { return c } -// WithEndpointDiscovery will set whether or not to use endpoint discovery. -func (c *Config) WithEndpointDiscovery(t bool) *Config { - c.EnableEndpointDiscovery = &t - return c -} - -// WithDisableEndpointHostPrefix will set whether or not to use modeled host prefix -// when making requests. -func (c *Config) WithDisableEndpointHostPrefix(t bool) *Config { - c.DisableEndpointHostPrefix = &t - return c -} - // MergeIn merges the passed in configs into the existing config object. func (c *Config) MergeIn(cfgs ...*Config) { for _, other := range cfgs { @@ -512,14 +476,6 @@ func mergeInConfig(dst *Config, other *Config) { if other.EnforceShouldRetryCheck != nil { dst.EnforceShouldRetryCheck = other.EnforceShouldRetryCheck } - - if other.EnableEndpointDiscovery != nil { - dst.EnableEndpointDiscovery = other.EnableEndpointDiscovery - } - - if other.DisableEndpointHostPrefix != nil { - dst.DisableEndpointHostPrefix = other.DisableEndpointHostPrefix - } } // Copy will return a shallow copy of the Config object. If any additional diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/context.go similarity index 58% rename from vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go rename to vendor/github.com/aws/aws-sdk-go/aws/context.go index 2866f9a7f..79f426853 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/context.go @@ -1,8 +1,8 @@ -// +build !go1.9 - package aws -import "time" +import ( + "time" +) // Context is an copy of the Go v1.7 stdlib's context.Context interface. // It is represented as a SDK interface to enable you to use the "WithContext" @@ -35,3 +35,37 @@ type Context interface { // functions. Value(key interface{}) interface{} } + +// BackgroundContext returns a context that will never be canceled, has no +// values, and no deadline. This context is used by the SDK to provide +// backwards compatibility with non-context API operations and functionality. +// +// Go 1.6 and before: +// This context function is equivalent to context.Background in the Go stdlib. +// +// Go 1.7 and later: +// The context returned will be the value returned by context.Background() +// +// See https://golang.org/pkg/context for more information on Contexts. +func BackgroundContext() Context { + return backgroundCtx +} + +// SleepWithContext will wait for the timer duration to expire, or the context +// is canceled. Which ever happens first. If the context is canceled the Context's +// error will be returned. +// +// Expects Context to always return a non-nil error if the Done channel is closed. +func SleepWithContext(ctx Context, dur time.Duration) error { + t := time.NewTimer(dur) + defer t.Stop() + + select { + case <-t.C: + break + case <-ctx.Done(): + return ctx.Err() + } + + return nil +} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go similarity index 59% rename from vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go rename to vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go index 66c5945db..8fdda5303 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go @@ -39,18 +39,3 @@ func (e *emptyCtx) String() string { var ( backgroundCtx = new(emptyCtx) ) - -// BackgroundContext returns a context that will never be canceled, has no -// values, and no deadline. This context is used by the SDK to provide -// backwards compatibility with non-context API operations and functionality. -// -// Go 1.6 and before: -// This context function is equivalent to context.Background in the Go stdlib. -// -// Go 1.7 and later: -// The context returned will be the value returned by context.Background() -// -// See https://golang.org/pkg/context for more information on Contexts. -func BackgroundContext() Context { - return backgroundCtx -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go b/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go new file mode 100644 index 000000000..064f75c92 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go @@ -0,0 +1,9 @@ +// +build go1.7 + +package aws + +import "context" + +var ( + backgroundCtx = context.Background() +) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go b/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go deleted file mode 100644 index 3718b26e1..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go +++ /dev/null @@ -1,11 +0,0 @@ -// +build go1.9 - -package aws - -import "context" - -// Context is an alias of the Go stdlib's context.Context interface. -// It can be used within the SDK's API operation "WithContext" methods. -// -// See https://golang.org/pkg/context on how to use contexts. -type Context = context.Context diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go b/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go deleted file mode 100644 index 9c29f29af..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go +++ /dev/null @@ -1,20 +0,0 @@ -// +build go1.7 - -package aws - -import "context" - -// BackgroundContext returns a context that will never be canceled, has no -// values, and no deadline. This context is used by the SDK to provide -// backwards compatibility with non-context API operations and functionality. -// -// Go 1.6 and before: -// This context function is equivalent to context.Background in the Go stdlib. -// -// Go 1.7 and later: -// The context returned will be the value returned by context.Background() -// -// See https://golang.org/pkg/context for more information on Contexts. -func BackgroundContext() Context { - return context.Background() -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go b/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go deleted file mode 100644 index 304fd1561..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go +++ /dev/null @@ -1,24 +0,0 @@ -package aws - -import ( - "time" -) - -// SleepWithContext will wait for the timer duration to expire, or the context -// is canceled. Which ever happens first. If the context is canceled the Context's -// error will be returned. -// -// Expects Context to always return a non-nil error if the Done channel is closed. -func SleepWithContext(ctx Context, dur time.Duration) error { - t := time.NewTimer(dur) - defer t.Stop() - - select { - case <-t.C: - break - case <-ctx.Done(): - return ctx.Err() - } - - return nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go index f8853d78a..cfcddf3dc 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go @@ -72,9 +72,9 @@ var ValidateReqSigHandler = request.NamedHandler{ signedTime = r.LastSignedAt } - // 5 minutes to allow for some clock skew/delays in transmission. + // 10 minutes to allow for some clock skew/delays in transmission. // Would be improved with aws/aws-sdk-go#423 - if signedTime.Add(5 * time.Minute).After(time.Now()) { + if signedTime.Add(10 * time.Minute).After(time.Now()) { return } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go index ab69c7a6f..a15f496bc 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go @@ -17,7 +17,7 @@ var SDKVersionUserAgentHandler = request.NamedHandler{ } const execEnvVar = `AWS_EXECUTION_ENV` -const execEnvUAKey = `exec-env` +const execEnvUAKey = `exec_env` // AddHostExecEnvUserAgentHander is a request handler appending the SDK's // execution environment to the user agent. diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go index 3ad1e798d..f298d6596 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go @@ -9,7 +9,9 @@ var ( // providers in the ChainProvider. // // This has been deprecated. For verbose error messaging set - // aws.Config.CredentialsChainVerboseErrors to true. + // aws.Config.CredentialsChainVerboseErrors to true + // + // @readonly ErrNoValidProvidersFoundInChain = awserr.New("NoCredentialProviders", `no valid providers in chain. Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors`, diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go index 4af592158..a270844df 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go @@ -49,11 +49,8 @@ package credentials import ( - "fmt" "sync" "time" - - "github.com/aws/aws-sdk-go/aws/awserr" ) // AnonymousCredentials is an empty Credential object that can be used as @@ -67,6 +64,8 @@ import ( // Credentials: credentials.AnonymousCredentials, // }))) // // Access public S3 buckets. +// +// @readonly var AnonymousCredentials = NewStaticCredentials("", "", "") // A Value is the AWS credentials value for individual credential fields. @@ -84,12 +83,6 @@ type Value struct { ProviderName string } -// HasKeys returns if the credentials Value has both AccessKeyID and -// SecretAccessKey value set. -func (v Value) HasKeys() bool { - return len(v.AccessKeyID) != 0 && len(v.SecretAccessKey) != 0 -} - // A Provider is the interface for any component which will provide credentials // Value. A provider is required to manage its own Expired state, and what to // be expired means. @@ -106,14 +99,6 @@ type Provider interface { IsExpired() bool } -// An Expirer is an interface that Providers can implement to expose the expiration -// time, if known. If the Provider cannot accurately provide this info, -// it should not implement this interface. -type Expirer interface { - // The time at which the credentials are no longer valid - ExpiresAt() time.Time -} - // An ErrorProvider is a stub credentials provider that always returns an error // this is used by the SDK when construction a known provider is not possible // due to an error. @@ -180,11 +165,6 @@ func (e *Expiry) IsExpired() bool { return e.expiration.Before(curTime()) } -// ExpiresAt returns the expiration time of the credential -func (e *Expiry) ExpiresAt() time.Time { - return e.expiration -} - // A Credentials provides concurrency safe retrieval of AWS credentials Value. // Credentials will cache the credentials value until they expire. Once the value // expires the next Get will attempt to retrieve valid credentials. @@ -277,23 +257,3 @@ func (c *Credentials) IsExpired() bool { func (c *Credentials) isExpired() bool { return c.forceRefresh || c.provider.IsExpired() } - -// ExpiresAt provides access to the functionality of the Expirer interface of -// the underlying Provider, if it supports that interface. Otherwise, it returns -// an error. -func (c *Credentials) ExpiresAt() (time.Time, error) { - c.m.RLock() - defer c.m.RUnlock() - - expirer, ok := c.provider.(Expirer) - if !ok { - return time.Time{}, awserr.New("ProviderNotExpirer", - fmt.Sprintf("provider %s does not support ExpiresAt()", c.creds.ProviderName), - nil) - } - if c.forceRefresh { - // set expiration time to the distant past - return time.Time{}, nil - } - return expirer.ExpiresAt(), nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go index 43d4ed386..0ed791be6 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds/ec2_role_provider.go @@ -11,7 +11,6 @@ import ( "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/ec2metadata" - "github.com/aws/aws-sdk-go/aws/request" "github.com/aws/aws-sdk-go/internal/sdkuri" ) @@ -143,8 +142,7 @@ func requestCredList(client *ec2metadata.EC2Metadata) ([]string, error) { } if err := s.Err(); err != nil { - return nil, awserr.New(request.ErrCodeSerialization, - "failed to read EC2 instance role from metadata service", err) + return nil, awserr.New("SerializationError", "failed to read EC2 instance role from metadata service", err) } return credsList, nil @@ -166,7 +164,7 @@ func requestCred(client *ec2metadata.EC2Metadata, credsName string) (ec2RoleCred respCreds := ec2RoleCredRespBody{} if err := json.NewDecoder(strings.NewReader(resp)).Decode(&respCreds); err != nil { return ec2RoleCredRespBody{}, - awserr.New(request.ErrCodeSerialization, + awserr.New("SerializationError", fmt.Sprintf("failed to decode %s EC2 instance role credentials", credsName), err) } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go index c2b2c5d65..a4cec5c55 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/endpointcreds/provider.go @@ -39,7 +39,6 @@ import ( "github.com/aws/aws-sdk-go/aws/client/metadata" "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil" ) // ProviderName is the name of the credentials provider. @@ -66,10 +65,6 @@ type Provider struct { // // If ExpiryWindow is 0 or less it will be ignored. ExpiryWindow time.Duration - - // Optional authorization token value if set will be used as the value of - // the Authorization header of the endpoint credential request. - AuthorizationToken string } // NewProviderClient returns a credentials Provider for retrieving AWS credentials @@ -157,9 +152,6 @@ func (p *Provider) getCredentials() (*getCredentialsOutput, error) { out := &getCredentialsOutput{} req := p.Client.NewRequest(op, nil, out) req.HTTPRequest.Header.Set("Accept", "application/json") - if authToken := p.AuthorizationToken; len(authToken) != 0 { - req.HTTPRequest.Header.Set("Authorization", authToken) - } return out, req.Send() } @@ -175,7 +167,7 @@ func unmarshalHandler(r *request.Request) { out := r.Data.(*getCredentialsOutput) if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&out); err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, + r.Error = awserr.New("SerializationError", "failed to decode endpoint credentials", err, ) @@ -186,15 +178,11 @@ func unmarshalError(r *request.Request) { defer r.HTTPResponse.Body.Close() var errOut errorOutput - err := jsonutil.UnmarshalJSONError(&errOut, r.HTTPResponse.Body) - if err != nil { - r.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, - "failed to decode error message", err), - r.HTTPResponse.StatusCode, - r.RequestID, + if err := json.NewDecoder(r.HTTPResponse.Body).Decode(&errOut); err != nil { + r.Error = awserr.New("SerializationError", + "failed to decode endpoint credentials", + err, ) - return } // Response body format is not consistent between metadata endpoints. diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go index 54c5cf733..c14231a16 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go @@ -12,10 +12,14 @@ const EnvProviderName = "EnvProvider" var ( // ErrAccessKeyIDNotFound is returned when the AWS Access Key ID can't be // found in the process's environment. + // + // @readonly ErrAccessKeyIDNotFound = awserr.New("EnvAccessKeyNotFound", "AWS_ACCESS_KEY_ID or AWS_ACCESS_KEY not found in environment", nil) // ErrSecretAccessKeyNotFound is returned when the AWS Secret Access Key // can't be found in the process's environment. + // + // @readonly ErrSecretAccessKeyNotFound = awserr.New("EnvSecretNotFound", "AWS_SECRET_ACCESS_KEY or AWS_SECRET_KEY not found in environment", nil) ) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go deleted file mode 100644 index 1980c8c14..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go +++ /dev/null @@ -1,425 +0,0 @@ -/* -Package processcreds is a credential Provider to retrieve `credential_process` -credentials. - -WARNING: The following describes a method of sourcing credentials from an external -process. This can potentially be dangerous, so proceed with caution. Other -credential providers should be preferred if at all possible. If using this -option, you should make sure that the config file is as locked down as possible -using security best practices for your operating system. - -You can use credentials from a `credential_process` in a variety of ways. - -One way is to setup your shared config file, located in the default -location, with the `credential_process` key and the command you want to be -called. You also need to set the AWS_SDK_LOAD_CONFIG environment variable -(e.g., `export AWS_SDK_LOAD_CONFIG=1`) to use the shared config file. - - [default] - credential_process = /command/to/call - -Creating a new session will use the credential process to retrieve credentials. -NOTE: If there are credentials in the profile you are using, the credential -process will not be used. - - // Initialize a session to load credentials. - sess, _ := session.NewSession(&aws.Config{ - Region: aws.String("us-east-1")}, - ) - - // Create S3 service client to use the credentials. - svc := s3.New(sess) - -Another way to use the `credential_process` method is by using -`credentials.NewCredentials()` and providing a command to be executed to -retrieve credentials: - - // Create credentials using the ProcessProvider. - creds := processcreds.NewCredentials("/path/to/command") - - // Create service client value configured for credentials. - svc := s3.New(sess, &aws.Config{Credentials: creds}) - -You can set a non-default timeout for the `credential_process` with another -constructor, `credentials.NewCredentialsTimeout()`, providing the timeout. To -set a one minute timeout: - - // Create credentials using the ProcessProvider. - creds := processcreds.NewCredentialsTimeout( - "/path/to/command", - time.Duration(500) * time.Millisecond) - -If you need more control, you can set any configurable options in the -credentials using one or more option functions. For example, you can set a two -minute timeout, a credential duration of 60 minutes, and a maximum stdout -buffer size of 2k. - - creds := processcreds.NewCredentials( - "/path/to/command", - func(opt *ProcessProvider) { - opt.Timeout = time.Duration(2) * time.Minute - opt.Duration = time.Duration(60) * time.Minute - opt.MaxBufSize = 2048 - }) - -You can also use your own `exec.Cmd`: - - // Create an exec.Cmd - myCommand := exec.Command("/path/to/command") - - // Create credentials using your exec.Cmd and custom timeout - creds := processcreds.NewCredentialsCommand( - myCommand, - func(opt *processcreds.ProcessProvider) { - opt.Timeout = time.Duration(1) * time.Second - }) -*/ -package processcreds - -import ( - "bytes" - "encoding/json" - "fmt" - "io" - "io/ioutil" - "os" - "os/exec" - "runtime" - "strings" - "time" - - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/aws/credentials" -) - -const ( - // ProviderName is the name this credentials provider will label any - // returned credentials Value with. - ProviderName = `ProcessProvider` - - // ErrCodeProcessProviderParse error parsing process output - ErrCodeProcessProviderParse = "ProcessProviderParseError" - - // ErrCodeProcessProviderVersion version error in output - ErrCodeProcessProviderVersion = "ProcessProviderVersionError" - - // ErrCodeProcessProviderRequired required attribute missing in output - ErrCodeProcessProviderRequired = "ProcessProviderRequiredError" - - // ErrCodeProcessProviderExecution execution of command failed - ErrCodeProcessProviderExecution = "ProcessProviderExecutionError" - - // errMsgProcessProviderTimeout process took longer than allowed - errMsgProcessProviderTimeout = "credential process timed out" - - // errMsgProcessProviderProcess process error - errMsgProcessProviderProcess = "error in credential_process" - - // errMsgProcessProviderParse problem parsing output - errMsgProcessProviderParse = "parse failed of credential_process output" - - // errMsgProcessProviderVersion version error in output - errMsgProcessProviderVersion = "wrong version in process output (not 1)" - - // errMsgProcessProviderMissKey missing access key id in output - errMsgProcessProviderMissKey = "missing AccessKeyId in process output" - - // errMsgProcessProviderMissSecret missing secret acess key in output - errMsgProcessProviderMissSecret = "missing SecretAccessKey in process output" - - // errMsgProcessProviderPrepareCmd prepare of command failed - errMsgProcessProviderPrepareCmd = "failed to prepare command" - - // errMsgProcessProviderEmptyCmd command must not be empty - errMsgProcessProviderEmptyCmd = "command must not be empty" - - // errMsgProcessProviderPipe failed to initialize pipe - errMsgProcessProviderPipe = "failed to initialize pipe" - - // DefaultDuration is the default amount of time in minutes that the - // credentials will be valid for. - DefaultDuration = time.Duration(15) * time.Minute - - // DefaultBufSize limits buffer size from growing to an enormous - // amount due to a faulty process. - DefaultBufSize = 1024 - - // DefaultTimeout default limit on time a process can run. - DefaultTimeout = time.Duration(1) * time.Minute -) - -// ProcessProvider satisfies the credentials.Provider interface, and is a -// client to retrieve credentials from a process. -type ProcessProvider struct { - staticCreds bool - credentials.Expiry - originalCommand []string - - // Expiry duration of the credentials. Defaults to 15 minutes if not set. - Duration time.Duration - - // ExpiryWindow will allow the credentials to trigger refreshing prior to - // the credentials actually expiring. This is beneficial so race conditions - // with expiring credentials do not cause request to fail unexpectedly - // due to ExpiredTokenException exceptions. - // - // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true - // 10 seconds before the credentials are actually expired. - // - // If ExpiryWindow is 0 or less it will be ignored. - ExpiryWindow time.Duration - - // A string representing an os command that should return a JSON with - // credential information. - command *exec.Cmd - - // MaxBufSize limits memory usage from growing to an enormous - // amount due to a faulty process. - MaxBufSize int - - // Timeout limits the time a process can run. - Timeout time.Duration -} - -// NewCredentials returns a pointer to a new Credentials object wrapping the -// ProcessProvider. The credentials will expire every 15 minutes by default. -func NewCredentials(command string, options ...func(*ProcessProvider)) *credentials.Credentials { - p := &ProcessProvider{ - command: exec.Command(command), - Duration: DefaultDuration, - Timeout: DefaultTimeout, - MaxBufSize: DefaultBufSize, - } - - for _, option := range options { - option(p) - } - - return credentials.NewCredentials(p) -} - -// NewCredentialsTimeout returns a pointer to a new Credentials object with -// the specified command and timeout, and default duration and max buffer size. -func NewCredentialsTimeout(command string, timeout time.Duration) *credentials.Credentials { - p := NewCredentials(command, func(opt *ProcessProvider) { - opt.Timeout = timeout - }) - - return p -} - -// NewCredentialsCommand returns a pointer to a new Credentials object with -// the specified command, and default timeout, duration and max buffer size. -func NewCredentialsCommand(command *exec.Cmd, options ...func(*ProcessProvider)) *credentials.Credentials { - p := &ProcessProvider{ - command: command, - Duration: DefaultDuration, - Timeout: DefaultTimeout, - MaxBufSize: DefaultBufSize, - } - - for _, option := range options { - option(p) - } - - return credentials.NewCredentials(p) -} - -type credentialProcessResponse struct { - Version int - AccessKeyID string `json:"AccessKeyId"` - SecretAccessKey string - SessionToken string - Expiration *time.Time -} - -// Retrieve executes the 'credential_process' and returns the credentials. -func (p *ProcessProvider) Retrieve() (credentials.Value, error) { - out, err := p.executeCredentialProcess() - if err != nil { - return credentials.Value{ProviderName: ProviderName}, err - } - - // Serialize and validate response - resp := &credentialProcessResponse{} - if err = json.Unmarshal(out, resp); err != nil { - return credentials.Value{ProviderName: ProviderName}, awserr.New( - ErrCodeProcessProviderParse, - fmt.Sprintf("%s: %s", errMsgProcessProviderParse, string(out)), - err) - } - - if resp.Version != 1 { - return credentials.Value{ProviderName: ProviderName}, awserr.New( - ErrCodeProcessProviderVersion, - errMsgProcessProviderVersion, - nil) - } - - if len(resp.AccessKeyID) == 0 { - return credentials.Value{ProviderName: ProviderName}, awserr.New( - ErrCodeProcessProviderRequired, - errMsgProcessProviderMissKey, - nil) - } - - if len(resp.SecretAccessKey) == 0 { - return credentials.Value{ProviderName: ProviderName}, awserr.New( - ErrCodeProcessProviderRequired, - errMsgProcessProviderMissSecret, - nil) - } - - // Handle expiration - p.staticCreds = resp.Expiration == nil - if resp.Expiration != nil { - p.SetExpiration(*resp.Expiration, p.ExpiryWindow) - } - - return credentials.Value{ - ProviderName: ProviderName, - AccessKeyID: resp.AccessKeyID, - SecretAccessKey: resp.SecretAccessKey, - SessionToken: resp.SessionToken, - }, nil -} - -// IsExpired returns true if the credentials retrieved are expired, or not yet -// retrieved. -func (p *ProcessProvider) IsExpired() bool { - if p.staticCreds { - return false - } - return p.Expiry.IsExpired() -} - -// prepareCommand prepares the command to be executed. -func (p *ProcessProvider) prepareCommand() error { - - var cmdArgs []string - if runtime.GOOS == "windows" { - cmdArgs = []string{"cmd.exe", "/C"} - } else { - cmdArgs = []string{"sh", "-c"} - } - - if len(p.originalCommand) == 0 { - p.originalCommand = make([]string, len(p.command.Args)) - copy(p.originalCommand, p.command.Args) - - // check for empty command because it succeeds - if len(strings.TrimSpace(p.originalCommand[0])) < 1 { - return awserr.New( - ErrCodeProcessProviderExecution, - fmt.Sprintf( - "%s: %s", - errMsgProcessProviderPrepareCmd, - errMsgProcessProviderEmptyCmd), - nil) - } - } - - cmdArgs = append(cmdArgs, p.originalCommand...) - p.command = exec.Command(cmdArgs[0], cmdArgs[1:]...) - p.command.Env = os.Environ() - - return nil -} - -// executeCredentialProcess starts the credential process on the OS and -// returns the results or an error. -func (p *ProcessProvider) executeCredentialProcess() ([]byte, error) { - - if err := p.prepareCommand(); err != nil { - return nil, err - } - - // Setup the pipes - outReadPipe, outWritePipe, err := os.Pipe() - if err != nil { - return nil, awserr.New( - ErrCodeProcessProviderExecution, - errMsgProcessProviderPipe, - err) - } - - p.command.Stderr = os.Stderr // display stderr on console for MFA - p.command.Stdout = outWritePipe // get creds json on process's stdout - p.command.Stdin = os.Stdin // enable stdin for MFA - - output := bytes.NewBuffer(make([]byte, 0, p.MaxBufSize)) - - stdoutCh := make(chan error, 1) - go readInput( - io.LimitReader(outReadPipe, int64(p.MaxBufSize)), - output, - stdoutCh) - - execCh := make(chan error, 1) - go executeCommand(*p.command, execCh) - - finished := false - var errors []error - for !finished { - select { - case readError := <-stdoutCh: - errors = appendError(errors, readError) - finished = true - case execError := <-execCh: - err := outWritePipe.Close() - errors = appendError(errors, err) - errors = appendError(errors, execError) - if errors != nil { - return output.Bytes(), awserr.NewBatchError( - ErrCodeProcessProviderExecution, - errMsgProcessProviderProcess, - errors) - } - case <-time.After(p.Timeout): - finished = true - return output.Bytes(), awserr.NewBatchError( - ErrCodeProcessProviderExecution, - errMsgProcessProviderTimeout, - errors) // errors can be nil - } - } - - out := output.Bytes() - - if runtime.GOOS == "windows" { - // windows adds slashes to quotes - out = []byte(strings.Replace(string(out), `\"`, `"`, -1)) - } - - return out, nil -} - -// appendError conveniently checks for nil before appending slice -func appendError(errors []error, err error) []error { - if err != nil { - return append(errors, err) - } - return errors -} - -func executeCommand(cmd exec.Cmd, exec chan error) { - // Start the command - err := cmd.Start() - if err == nil { - err = cmd.Wait() - } - - exec <- err -} - -func readInput(r io.Reader, w io.Writer, read chan error) { - tee := io.TeeReader(r, w) - - _, err := ioutil.ReadAll(tee) - - if err == io.EOF { - err = nil - } - - read <- err // will only arrive here when write end of pipe is closed -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go index e15514958..51e21e0f3 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go @@ -4,8 +4,9 @@ import ( "fmt" "os" + "github.com/go-ini/ini" + "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/internal/ini" "github.com/aws/aws-sdk-go/internal/shareddefaults" ) @@ -76,37 +77,36 @@ func (p *SharedCredentialsProvider) IsExpired() bool { // The credentials retrieved from the profile will be returned or error. Error will be // returned if it fails to read from the file, or the data is invalid. func loadProfile(filename, profile string) (Value, error) { - config, err := ini.OpenFile(filename) + config, err := ini.Load(filename) if err != nil { return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsLoad", "failed to load shared credentials file", err) } - - iniProfile, ok := config.GetSection(profile) - if !ok { - return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsLoad", "failed to get profile", nil) + iniProfile, err := config.GetSection(profile) + if err != nil { + return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsLoad", "failed to get profile", err) } - id := iniProfile.String("aws_access_key_id") - if len(id) == 0 { + id, err := iniProfile.GetKey("aws_access_key_id") + if err != nil { return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsAccessKey", fmt.Sprintf("shared credentials %s in %s did not contain aws_access_key_id", profile, filename), - nil) + err) } - secret := iniProfile.String("aws_secret_access_key") - if len(secret) == 0 { + secret, err := iniProfile.GetKey("aws_secret_access_key") + if err != nil { return Value{ProviderName: SharedCredsProviderName}, awserr.New("SharedCredsSecret", fmt.Sprintf("shared credentials %s in %s did not contain aws_secret_access_key", profile, filename), nil) } // Default to empty string if not found - token := iniProfile.String("aws_session_token") + token := iniProfile.Key("aws_session_token") return Value{ - AccessKeyID: id, - SecretAccessKey: secret, - SessionToken: token, + AccessKeyID: id.String(), + SecretAccessKey: secret.String(), + SessionToken: token.String(), ProviderName: SharedCredsProviderName, }, nil } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go index 531139e39..4f5dab3fc 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go @@ -9,6 +9,8 @@ const StaticProviderName = "StaticProvider" var ( // ErrStaticCredentialsEmpty is emitted when static credentials are empty. + // + // @readonly ErrStaticCredentialsEmpty = awserr.New("EmptyStaticCreds", "static credentials are empty", nil) ) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go index 2e528d130..4108e433e 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/assume_role_provider.go @@ -80,18 +80,16 @@ package stscreds import ( "fmt" - "os" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/internal/sdkrand" "github.com/aws/aws-sdk-go/service/sts" ) -// StdinTokenProvider will prompt on stderr and read from stdin for a string value. +// StdinTokenProvider will prompt on stdout and read from stdin for a string value. // An error is returned if reading from stdin fails. // // Use this function go read MFA tokens from stdin. The function makes no attempt @@ -104,7 +102,7 @@ import ( // Will wait forever until something is provided on the stdin. func StdinTokenProvider() (string, error) { var v string - fmt.Fprintf(os.Stderr, "Assume Role MFA token code: ") + fmt.Printf("Assume Role MFA token code: ") _, err := fmt.Scanln(&v) return v, err @@ -195,18 +193,6 @@ type AssumeRoleProvider struct { // // If ExpiryWindow is 0 or less it will be ignored. ExpiryWindow time.Duration - - // MaxJitterFrac reduces the effective Duration of each credential requested - // by a random percentage between 0 and MaxJitterFraction. MaxJitterFrac must - // have a value between 0 and 1. Any other value may lead to expected behavior. - // With a MaxJitterFrac value of 0, default) will no jitter will be used. - // - // For example, with a Duration of 30m and a MaxJitterFrac of 0.1, the - // AssumeRole call will be made with an arbitrary Duration between 27m and - // 30m. - // - // MaxJitterFrac should not be negative. - MaxJitterFrac float64 } // NewCredentials returns a pointer to a new Credentials object wrapping the @@ -258,6 +244,7 @@ func NewCredentialsWithClient(svc AssumeRoler, roleARN string, options ...func(* // Retrieve generates a new set of temporary credentials using STS. func (p *AssumeRoleProvider) Retrieve() (credentials.Value, error) { + // Apply defaults where parameters are not set. if p.RoleSessionName == "" { // Try to work out a role name that will hopefully end up unique. @@ -267,9 +254,8 @@ func (p *AssumeRoleProvider) Retrieve() (credentials.Value, error) { // Expire as often as AWS permits. p.Duration = DefaultDuration } - jitter := time.Duration(sdkrand.SeededRand.Float64() * p.MaxJitterFrac * float64(p.Duration)) input := &sts.AssumeRoleInput{ - DurationSeconds: aws.Int64(int64((p.Duration - jitter) / time.Second)), + DurationSeconds: aws.Int64(int64(p.Duration / time.Second)), RoleArn: aws.String(p.RoleARN), RoleSessionName: aws.String(p.RoleSessionName), ExternalId: p.ExternalID, diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go deleted file mode 100644 index b419210f6..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go +++ /dev/null @@ -1,99 +0,0 @@ -package stscreds - -import ( - "fmt" - "io/ioutil" - "strconv" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/aws/client" - "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/service/sts" - "github.com/aws/aws-sdk-go/service/sts/stsiface" -) - -const ( - // ErrCodeWebIdentity will be used as an error code when constructing - // a new error to be returned during session creation or retrieval. - ErrCodeWebIdentity = "WebIdentityErr" - - // WebIdentityProviderName is the web identity provider name - WebIdentityProviderName = "WebIdentityCredentials" -) - -// now is used to return a time.Time object representing -// the current time. This can be used to easily test and -// compare test values. -var now = func() time.Time { - return time.Now() -} - -// WebIdentityRoleProvider is used to retrieve credentials using -// an OIDC token. -type WebIdentityRoleProvider struct { - credentials.Expiry - - client stsiface.STSAPI - ExpiryWindow time.Duration - - tokenFilePath string - roleARN string - roleSessionName string -} - -// NewWebIdentityCredentials will return a new set of credentials with a given -// configuration, role arn, and token file path. -func NewWebIdentityCredentials(c client.ConfigProvider, roleARN, roleSessionName, path string) *credentials.Credentials { - svc := sts.New(c) - p := NewWebIdentityRoleProvider(svc, roleARN, roleSessionName, path) - return credentials.NewCredentials(p) -} - -// NewWebIdentityRoleProvider will return a new WebIdentityRoleProvider with the -// provided stsiface.STSAPI -func NewWebIdentityRoleProvider(svc stsiface.STSAPI, roleARN, roleSessionName, path string) *WebIdentityRoleProvider { - return &WebIdentityRoleProvider{ - client: svc, - tokenFilePath: path, - roleARN: roleARN, - roleSessionName: roleSessionName, - } -} - -// Retrieve will attempt to assume a role from a token which is located at -// 'WebIdentityTokenFilePath' specified destination and if that is empty an -// error will be returned. -func (p *WebIdentityRoleProvider) Retrieve() (credentials.Value, error) { - b, err := ioutil.ReadFile(p.tokenFilePath) - if err != nil { - errMsg := fmt.Sprintf("unable to read file at %s", p.tokenFilePath) - return credentials.Value{}, awserr.New(ErrCodeWebIdentity, errMsg, err) - } - - sessionName := p.roleSessionName - if len(sessionName) == 0 { - // session name is used to uniquely identify a session. This simply - // uses unix time in nanoseconds to uniquely identify sessions. - sessionName = strconv.FormatInt(now().UnixNano(), 10) - } - resp, err := p.client.AssumeRoleWithWebIdentity(&sts.AssumeRoleWithWebIdentityInput{ - RoleArn: &p.roleARN, - RoleSessionName: &sessionName, - WebIdentityToken: aws.String(string(b)), - }) - if err != nil { - return credentials.Value{}, awserr.New(ErrCodeWebIdentity, "failed to retrieve credentials", err) - } - - p.SetExpiration(aws.TimeValue(resp.Credentials.Expiration), p.ExpiryWindow) - - value := credentials.Value{ - AccessKeyID: aws.StringValue(resp.Credentials.AccessKeyId), - SecretAccessKey: aws.StringValue(resp.Credentials.SecretAccessKey), - SessionToken: aws.StringValue(resp.Credentials.SessionToken), - ProviderName: WebIdentityProviderName, - } - return value, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go index 25a66d1dd..152d785b3 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/doc.go @@ -1,61 +1,30 @@ -// Package csm provides the Client Side Monitoring (CSM) client which enables -// sending metrics via UDP connection to the CSM agent. This package provides -// control options, and configuration for the CSM client. The client can be -// controlled manually, or automatically via the SDK's Session configuration. +// Package csm provides Client Side Monitoring (CSM) which enables sending metrics +// via UDP connection. Using the Start function will enable the reporting of +// metrics on a given port. If Start is called, with different parameters, again, +// a panic will occur. // -// Enabling CSM client via SDK's Session configuration -// -// The CSM client can be enabled automatically via SDK's Session configuration. -// The SDK's session configuration enables the CSM client if the AWS_CSM_PORT -// environment variable is set to a non-empty value. -// -// The configuration options for the CSM client via the SDK's session -// configuration are: -// -// * AWS_CSM_PORT= -// The port number the CSM agent will receive metrics on. -// -// * AWS_CSM_HOST= -// The hostname, or IP address the CSM agent will receive metrics on. -// Without port number. -// -// Manually enabling the CSM client -// -// The CSM client can be started, paused, and resumed manually. The Start -// function will enable the CSM client to publish metrics to the CSM agent. It -// is safe to call Start concurrently, but if Start is called additional times -// with different ClientID or address it will panic. +// Pause can be called to pause any metrics publishing on a given port. Sessions +// that have had their handlers modified via InjectHandlers may still be used. +// However, the handlers will act as a no-op meaning no metrics will be published. // +// Example: // r, err := csm.Start("clientID", ":31000") // if err != nil { // panic(fmt.Errorf("failed starting CSM: %v", err)) // } // -// When controlling the CSM client manually, you must also inject its request -// handlers into the SDK's Session configuration for the SDK's API clients to -// publish metrics. -// // sess, err := session.NewSession(&aws.Config{}) // if err != nil { // panic(fmt.Errorf("failed loading session: %v", err)) // } // -// // Add CSM client's metric publishing request handlers to the SDK's -// // Session Configuration. // r.InjectHandlers(&sess.Handlers) // -// Controlling CSM client -// -// Once the CSM client has been enabled the Get function will return a Reporter -// value that you can use to pause and resume the metrics published to the CSM -// agent. If Get function is called before the reporter is enabled with the -// Start function or via SDK's Session configuration nil will be returned. -// -// The Pause method can be called to stop the CSM client publishing metrics to -// the CSM agent. The Continue method will resume metric publishing. -// -// // Get the CSM client Reporter. -// r := csm.Get() +// client := s3.New(sess) +// resp, err := client.GetObject(&s3.GetObjectInput{ +// Bucket: aws.String("bucket"), +// Key: aws.String("key"), +// }) // // // Will pause monitoring // r.Pause() @@ -66,4 +35,12 @@ // // // Resume monitoring // r.Continue() +// +// Start returns a Reporter that is used to enable or disable monitoring. If +// access to the Reporter is required later, calling Get will return the Reporter +// singleton. +// +// Example: +// r := csm.Get() +// r.Continue() package csm diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go index 4b19e2800..2f0c6eac9 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/enable.go @@ -2,7 +2,6 @@ package csm import ( "fmt" - "strings" "sync" ) @@ -10,40 +9,19 @@ var ( lock sync.Mutex ) +// Client side metric handler names const ( - // DefaultPort is used when no port is specified. - DefaultPort = "31000" - - // DefaultHost is the host that will be used when none is specified. - DefaultHost = "127.0.0.1" + APICallMetricHandlerName = "awscsm.SendAPICallMetric" + APICallAttemptMetricHandlerName = "awscsm.SendAPICallAttemptMetric" ) -// AddressWithDefaults returns a CSM address built from the host and port -// values. If the host or port is not set, default values will be used -// instead. If host is "localhost" it will be replaced with "127.0.0.1". -func AddressWithDefaults(host, port string) string { - if len(host) == 0 || strings.EqualFold(host, "localhost") { - host = DefaultHost - } - - if len(port) == 0 { - port = DefaultPort - } - - // Only IP6 host can contain a colon - if strings.Contains(host, ":") { - return "[" + host + "]:" + port - } - - return host + ":" + port -} - -// Start will start a long running go routine to capture +// Start will start the a long running go routine to capture // client side metrics. Calling start multiple time will only // start the metric listener once and will panic if a different // client ID or port is passed in. // -// r, err := csm.Start("clientID", "127.0.0.1:31000") +// Example: +// r, err := csm.Start("clientID", "127.0.0.1:8094") // if err != nil { // panic(fmt.Errorf("expected no error, but received %v", err)) // } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go index 5bacc791a..4b0d630e4 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go @@ -3,8 +3,6 @@ package csm import ( "strconv" "time" - - "github.com/aws/aws-sdk-go/aws" ) type metricTime time.Time @@ -41,12 +39,6 @@ type metric struct { SDKException *string `json:"SdkException,omitempty"` SDKExceptionMessage *string `json:"SdkExceptionMessage,omitempty"` - FinalHTTPStatusCode *int `json:"FinalHttpStatusCode,omitempty"` - FinalAWSException *string `json:"FinalAwsException,omitempty"` - FinalAWSExceptionMessage *string `json:"FinalAwsExceptionMessage,omitempty"` - FinalSDKException *string `json:"FinalSdkException,omitempty"` - FinalSDKExceptionMessage *string `json:"FinalSdkExceptionMessage,omitempty"` - DestinationIP *string `json:"DestinationIp,omitempty"` ConnectionReused *int `json:"ConnectionReused,omitempty"` @@ -56,54 +48,4 @@ type metric struct { DNSLatency *int `json:"DnsLatency,omitempty"` TCPLatency *int `json:"TcpLatency,omitempty"` SSLLatency *int `json:"SslLatency,omitempty"` - - MaxRetriesExceeded *int `json:"MaxRetriesExceeded,omitempty"` -} - -func (m *metric) TruncateFields() { - m.ClientID = truncateString(m.ClientID, 255) - m.UserAgent = truncateString(m.UserAgent, 256) - - m.AWSException = truncateString(m.AWSException, 128) - m.AWSExceptionMessage = truncateString(m.AWSExceptionMessage, 512) - - m.SDKException = truncateString(m.SDKException, 128) - m.SDKExceptionMessage = truncateString(m.SDKExceptionMessage, 512) - - m.FinalAWSException = truncateString(m.FinalAWSException, 128) - m.FinalAWSExceptionMessage = truncateString(m.FinalAWSExceptionMessage, 512) - - m.FinalSDKException = truncateString(m.FinalSDKException, 128) - m.FinalSDKExceptionMessage = truncateString(m.FinalSDKExceptionMessage, 512) -} - -func truncateString(v *string, l int) *string { - if v != nil && len(*v) > l { - nv := (*v)[:l] - return &nv - } - - return v -} - -func (m *metric) SetException(e metricException) { - switch te := e.(type) { - case awsException: - m.AWSException = aws.String(te.exception) - m.AWSExceptionMessage = aws.String(te.message) - case sdkException: - m.SDKException = aws.String(te.exception) - m.SDKExceptionMessage = aws.String(te.message) - } -} - -func (m *metric) SetFinalException(e metricException) { - switch te := e.(type) { - case awsException: - m.FinalAWSException = aws.String(te.exception) - m.FinalAWSExceptionMessage = aws.String(te.message) - case sdkException: - m.FinalSDKException = aws.String(te.exception) - m.FinalSDKExceptionMessage = aws.String(te.message) - } } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go deleted file mode 100644 index 54a99280c..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go +++ /dev/null @@ -1,26 +0,0 @@ -package csm - -type metricException interface { - Exception() string - Message() string -} - -type requestException struct { - exception string - message string -} - -func (e requestException) Exception() string { - return e.exception -} -func (e requestException) Message() string { - return e.message -} - -type awsException struct { - requestException -} - -type sdkException struct { - requestException -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go b/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go index 0d3684914..11082e5ed 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go @@ -10,6 +10,11 @@ import ( "github.com/aws/aws-sdk-go/aws/request" ) +const ( + // DefaultPort is used when no port is specified + DefaultPort = "31000" +) + // Reporter will gather metrics of API requests made and // send those metrics to the CSM endpoint. type Reporter struct { @@ -77,29 +82,26 @@ func (rep *Reporter) sendAPICallAttemptMetric(r *request.Request) { if r.Error != nil { if awserr, ok := r.Error.(awserr.Error); ok { - m.SetException(getMetricException(awserr)) + setError(&m, awserr) } } - m.TruncateFields() rep.metricsCh.Push(m) } -func getMetricException(err awserr.Error) metricException { +func setError(m *metric, err awserr.Error) { msg := err.Error() code := err.Code() switch code { case "RequestError", - request.ErrCodeSerialization, + "SerializationError", request.CanceledErrorCode: - return sdkException{ - requestException{exception: code, message: msg}, - } + m.SDKException = &code + m.SDKExceptionMessage = &msg default: - return awsException{ - requestException{exception: code, message: msg}, - } + m.AWSException = &code + m.AWSExceptionMessage = &msg } } @@ -110,31 +112,16 @@ func (rep *Reporter) sendAPICallMetric(r *request.Request) { now := time.Now() m := metric{ - ClientID: aws.String(rep.clientID), - API: aws.String(r.Operation.Name), - Service: aws.String(r.ClientInfo.ServiceID), - Timestamp: (*metricTime)(&now), - UserAgent: aws.String(r.HTTPRequest.Header.Get("User-Agent")), - Type: aws.String("ApiCall"), - AttemptCount: aws.Int(r.RetryCount + 1), - Region: r.Config.Region, - Latency: aws.Int(int(time.Now().Sub(r.Time) / time.Millisecond)), - XAmzRequestID: aws.String(r.RequestID), - MaxRetriesExceeded: aws.Int(boolIntValue(r.RetryCount >= r.MaxRetries())), + ClientID: aws.String(rep.clientID), + API: aws.String(r.Operation.Name), + Service: aws.String(r.ClientInfo.ServiceID), + Timestamp: (*metricTime)(&now), + Type: aws.String("ApiCall"), + AttemptCount: aws.Int(r.RetryCount + 1), + Latency: aws.Int(int(time.Now().Sub(r.Time) / time.Millisecond)), + XAmzRequestID: aws.String(r.RequestID), } - if r.HTTPResponse != nil { - m.FinalHTTPStatusCode = aws.Int(r.HTTPResponse.StatusCode) - } - - if r.Error != nil { - if awserr, ok := r.Error.(awserr.Error); ok { - m.SetFinalException(getMetricException(awserr)) - } - } - - m.TruncateFields() - // TODO: Probably want to figure something out for logging dropped // metrics rep.metricsCh.Push(m) @@ -185,9 +172,8 @@ func (rep *Reporter) start() { } } -// Pause will pause the metric channel preventing any new metrics from being -// added. It is safe to call concurrently with other calls to Pause, but if -// called concurently with Continue can lead to unexpected state. +// Pause will pause the metric channel preventing any new metrics from +// being added. func (rep *Reporter) Pause() { lock.Lock() defer lock.Unlock() @@ -199,9 +185,8 @@ func (rep *Reporter) Pause() { rep.close() } -// Continue will reopen the metric channel and allow for monitoring to be -// resumed. It is safe to call concurrently with other calls to Continue, but -// if called concurently with Pause can lead to unexpected state. +// Continue will reopen the metric channel and allow for monitoring +// to be resumed. func (rep *Reporter) Continue() { lock.Lock() defer lock.Unlock() @@ -216,18 +201,10 @@ func (rep *Reporter) Continue() { rep.metricsCh.Continue() } -// Client side metric handler names -const ( - APICallMetricHandlerName = "awscsm.SendAPICallMetric" - APICallAttemptMetricHandlerName = "awscsm.SendAPICallAttemptMetric" -) - // InjectHandlers will will enable client side metrics and inject the proper // handlers to handle how metrics are sent. // -// InjectHandlers is NOT safe to call concurrently. Calling InjectHandlers -// multiple times may lead to unexpected behavior, (e.g. duplicate metrics). -// +// Example: // // Start must be called in order to inject the correct handlers // r, err := csm.Start("clientID", "127.0.0.1:8094") // if err != nil { @@ -244,22 +221,11 @@ func (rep *Reporter) InjectHandlers(handlers *request.Handlers) { return } - handlers.Complete.PushFrontNamed(request.NamedHandler{ - Name: APICallMetricHandlerName, - Fn: rep.sendAPICallMetric, - }) + apiCallHandler := request.NamedHandler{Name: APICallMetricHandlerName, Fn: rep.sendAPICallMetric} + apiCallAttemptHandler := request.NamedHandler{Name: APICallAttemptMetricHandlerName, Fn: rep.sendAPICallAttemptMetric} - handlers.CompleteAttempt.PushFrontNamed(request.NamedHandler{ - Name: APICallAttemptMetricHandlerName, - Fn: rep.sendAPICallAttemptMetric, - }) -} - -// boolIntValue return 1 for true and 0 for false. -func boolIntValue(b bool) int { - if b { - return 1 - } - - return 0 + handlers.Complete.PushFrontNamed(apiCallHandler) + handlers.Complete.PushFrontNamed(apiCallAttemptHandler) + + handlers.AfterRetry.PushFrontNamed(apiCallAttemptHandler) } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go index 23bb639e0..5040a2f64 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/defaults/defaults.go @@ -24,7 +24,6 @@ import ( "github.com/aws/aws-sdk-go/aws/ec2metadata" "github.com/aws/aws-sdk-go/aws/endpoints" "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/internal/shareddefaults" ) // A Defaults provides a collection of default values for SDK clients. @@ -113,8 +112,8 @@ func CredProviders(cfg *aws.Config, handlers request.Handlers) []credentials.Pro } const ( - httpProviderAuthorizationEnvVar = "AWS_CONTAINER_AUTHORIZATION_TOKEN" - httpProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_FULL_URI" + httpProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_FULL_URI" + ecsCredsProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI" ) // RemoteCredProvider returns a credentials provider for the default remote @@ -124,8 +123,8 @@ func RemoteCredProvider(cfg aws.Config, handlers request.Handlers) credentials.P return localHTTPCredProvider(cfg, handlers, u) } - if uri := os.Getenv(shareddefaults.ECSCredsProviderEnvVar); len(uri) > 0 { - u := fmt.Sprintf("%s%s", shareddefaults.ECSContainerCredentialsURI, uri) + if uri := os.Getenv(ecsCredsProviderEnvVar); len(uri) > 0 { + u := fmt.Sprintf("http://169.254.170.2%s", uri) return httpCredProvider(cfg, handlers, u) } @@ -188,7 +187,6 @@ func httpCredProvider(cfg aws.Config, handlers request.Handlers, u string) crede return endpointcreds.NewProviderClient(cfg, handlers, u, func(p *endpointcreds.Provider) { p.ExpiryWindow = 5 * time.Minute - p.AuthorizationToken = os.Getenv(httpProviderAuthorizationEnvVar) }, ) } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go index 2c8d5f56d..c215cd3f5 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go @@ -24,9 +24,8 @@ func (c *EC2Metadata) GetMetadata(p string) (string, error) { output := &metadataOutput{} req := c.NewRequest(op, nil, output) - err := req.Send() - return output.Content, err + return output.Content, req.Send() } // GetUserData returns the userdata that was configured for the service. If @@ -46,9 +45,8 @@ func (c *EC2Metadata) GetUserData() (string, error) { r.Error = awserr.New("NotFoundError", "user-data not found", r.Error) } }) - err := req.Send() - return output.Content, err + return output.Content, req.Send() } // GetDynamicData uses the path provided to request information from the EC2 @@ -63,9 +61,8 @@ func (c *EC2Metadata) GetDynamicData(p string) (string, error) { output := &metadataOutput{} req := c.NewRequest(op, nil, output) - err := req.Send() - return output.Content, err + return output.Content, req.Send() } // GetInstanceIdentityDocument retrieves an identity document describing an @@ -82,7 +79,7 @@ func (c *EC2Metadata) GetInstanceIdentityDocument() (EC2InstanceIdentityDocument doc := EC2InstanceIdentityDocument{} if err := json.NewDecoder(strings.NewReader(resp)).Decode(&doc); err != nil { return EC2InstanceIdentityDocument{}, - awserr.New(request.ErrCodeSerialization, + awserr.New("SerializationError", "failed to decode EC2 instance identity document", err) } @@ -101,7 +98,7 @@ func (c *EC2Metadata) IAMInfo() (EC2IAMInfo, error) { info := EC2IAMInfo{} if err := json.NewDecoder(strings.NewReader(resp)).Decode(&info); err != nil { return EC2IAMInfo{}, - awserr.New(request.ErrCodeSerialization, + awserr.New("SerializationError", "failed to decode EC2 IAM info", err) } @@ -121,10 +118,6 @@ func (c *EC2Metadata) Region() (string, error) { return "", err } - if len(resp) == 0 { - return "", awserr.New("EC2MetadataError", "invalid Region response", nil) - } - // returns region without the suffix. Eg: us-west-2a becomes us-west-2 return resp[:len(resp)-1], nil } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go index f0c1d31e7..ef5f73292 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go @@ -4,7 +4,7 @@ // This package's client can be disabled completely by setting the environment // variable "AWS_EC2_METADATA_DISABLED=true". This environment variable set to // true instructs the SDK to disable the EC2 Metadata client. The client cannot -// be used while the environment variable is set to true, (case insensitive). +// be used while the environemnt variable is set to true, (case insensitive). package ec2metadata import ( @@ -72,7 +72,6 @@ func NewClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegio cfg, metadata.ClientInfo{ ServiceName: ServiceName, - ServiceID: ServiceName, Endpoint: endpoint, APIVersion: "latest", }, @@ -92,9 +91,6 @@ func NewClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegio svc.Handlers.Send.SwapNamed(request.NamedHandler{ Name: corehandlers.SendHandler.Name, Fn: func(r *request.Request) { - r.HTTPResponse = &http.Response{ - Header: http.Header{}, - } r.Error = awserr.New( request.CanceledErrorCode, "EC2 IMDS access disabled via "+disableServiceEnvVar+" env var", @@ -123,7 +119,7 @@ func unmarshalHandler(r *request.Request) { defer r.HTTPResponse.Body.Close() b := &bytes.Buffer{} if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "unable to unmarshal EC2 metadata respose", err) + r.Error = awserr.New("SerializationError", "unable to unmarshal EC2 metadata respose", err) return } @@ -136,7 +132,7 @@ func unmarshalError(r *request.Request) { defer r.HTTPResponse.Body.Close() b := &bytes.Buffer{} if _, err := io.Copy(b, r.HTTPResponse.Body); err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "unable to unmarshal EC2 metadata error respose", err) + r.Error = awserr.New("SerializationError", "unable to unmarshal EC2 metadata error respose", err) return } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go index 87b9ff3ff..c04ba06c5 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go @@ -85,7 +85,6 @@ func decodeV3Endpoints(modelDef modelDefinition, opts DecodeModelOptions) (Resol custAddS3DualStack(p) custRmIotDataService(p) custFixAppAutoscalingChina(p) - custFixAppAutoscalingUsGov(p) } return ps, nil @@ -96,12 +95,7 @@ func custAddS3DualStack(p *partition) { return } - custAddDualstack(p, "s3") - custAddDualstack(p, "s3-control") -} - -func custAddDualstack(p *partition, svcName string) { - s, ok := p.Services[svcName] + s, ok := p.Services["s3"] if !ok { return } @@ -109,7 +103,7 @@ func custAddDualstack(p *partition, svcName string) { s.Defaults.HasDualStack = boxedTrue s.Defaults.DualStackHostname = "{service}.dualstack.{region}.{dnsSuffix}" - p.Services[svcName] = s + p.Services["s3"] = s } func custAddEC2Metadata(p *partition) { @@ -150,33 +144,6 @@ func custFixAppAutoscalingChina(p *partition) { p.Services[serviceName] = s } -func custFixAppAutoscalingUsGov(p *partition) { - if p.ID != "aws-us-gov" { - return - } - - const serviceName = "application-autoscaling" - s, ok := p.Services[serviceName] - if !ok { - return - } - - if a := s.Defaults.CredentialScope.Service; a != "" { - fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty credential scope service, got %s\n", a) - return - } - - if a := s.Defaults.Hostname; a != "" { - fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty hostname, got %s\n", a) - return - } - - s.Defaults.CredentialScope.Service = "application-autoscaling" - s.Defaults.Hostname = "autoscaling.{region}.amazonaws.com" - - p.Services[serviceName] = s -} - type decodeModelError struct { awsError } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go index 568d03145..86788100a 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go @@ -15,7 +15,6 @@ const ( // AWS Standard partition's regions. const ( - ApEast1RegionID = "ap-east-1" // Asia Pacific (Hong Kong). ApNortheast1RegionID = "ap-northeast-1" // Asia Pacific (Tokyo). ApNortheast2RegionID = "ap-northeast-2" // Asia Pacific (Seoul). ApSouth1RegionID = "ap-south-1" // Asia Pacific (Mumbai). @@ -23,7 +22,6 @@ const ( ApSoutheast2RegionID = "ap-southeast-2" // Asia Pacific (Sydney). CaCentral1RegionID = "ca-central-1" // Canada (Central). EuCentral1RegionID = "eu-central-1" // EU (Frankfurt). - EuNorth1RegionID = "eu-north-1" // EU (Stockholm). EuWest1RegionID = "eu-west-1" // EU (Ireland). EuWest2RegionID = "eu-west-2" // EU (London). EuWest3RegionID = "eu-west-3" // EU (Paris). @@ -42,10 +40,141 @@ const ( // AWS GovCloud (US) partition's regions. const ( - UsGovEast1RegionID = "us-gov-east-1" // AWS GovCloud (US-East). UsGovWest1RegionID = "us-gov-west-1" // AWS GovCloud (US). ) +// Service identifiers +const ( + A4bServiceID = "a4b" // A4b. + AcmServiceID = "acm" // Acm. + AcmPcaServiceID = "acm-pca" // AcmPca. + ApiMediatailorServiceID = "api.mediatailor" // ApiMediatailor. + ApiPricingServiceID = "api.pricing" // ApiPricing. + ApiSagemakerServiceID = "api.sagemaker" // ApiSagemaker. + ApigatewayServiceID = "apigateway" // Apigateway. + ApplicationAutoscalingServiceID = "application-autoscaling" // ApplicationAutoscaling. + Appstream2ServiceID = "appstream2" // Appstream2. + AthenaServiceID = "athena" // Athena. + AutoscalingServiceID = "autoscaling" // Autoscaling. + AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans. + BatchServiceID = "batch" // Batch. + BudgetsServiceID = "budgets" // Budgets. + CeServiceID = "ce" // Ce. + Cloud9ServiceID = "cloud9" // Cloud9. + ClouddirectoryServiceID = "clouddirectory" // Clouddirectory. + CloudformationServiceID = "cloudformation" // Cloudformation. + CloudfrontServiceID = "cloudfront" // Cloudfront. + CloudhsmServiceID = "cloudhsm" // Cloudhsm. + Cloudhsmv2ServiceID = "cloudhsmv2" // Cloudhsmv2. + CloudsearchServiceID = "cloudsearch" // Cloudsearch. + CloudtrailServiceID = "cloudtrail" // Cloudtrail. + CodebuildServiceID = "codebuild" // Codebuild. + CodecommitServiceID = "codecommit" // Codecommit. + CodedeployServiceID = "codedeploy" // Codedeploy. + CodepipelineServiceID = "codepipeline" // Codepipeline. + CodestarServiceID = "codestar" // Codestar. + CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity. + CognitoIdpServiceID = "cognito-idp" // CognitoIdp. + CognitoSyncServiceID = "cognito-sync" // CognitoSync. + ComprehendServiceID = "comprehend" // Comprehend. + ConfigServiceID = "config" // Config. + CurServiceID = "cur" // Cur. + DatapipelineServiceID = "datapipeline" // Datapipeline. + DaxServiceID = "dax" // Dax. + DevicefarmServiceID = "devicefarm" // Devicefarm. + DirectconnectServiceID = "directconnect" // Directconnect. + DiscoveryServiceID = "discovery" // Discovery. + DmsServiceID = "dms" // Dms. + DsServiceID = "ds" // Ds. + DynamodbServiceID = "dynamodb" // Dynamodb. + Ec2ServiceID = "ec2" // Ec2. + Ec2metadataServiceID = "ec2metadata" // Ec2metadata. + EcrServiceID = "ecr" // Ecr. + EcsServiceID = "ecs" // Ecs. + ElasticacheServiceID = "elasticache" // Elasticache. + ElasticbeanstalkServiceID = "elasticbeanstalk" // Elasticbeanstalk. + ElasticfilesystemServiceID = "elasticfilesystem" // Elasticfilesystem. + ElasticloadbalancingServiceID = "elasticloadbalancing" // Elasticloadbalancing. + ElasticmapreduceServiceID = "elasticmapreduce" // Elasticmapreduce. + ElastictranscoderServiceID = "elastictranscoder" // Elastictranscoder. + EmailServiceID = "email" // Email. + EntitlementMarketplaceServiceID = "entitlement.marketplace" // EntitlementMarketplace. + EsServiceID = "es" // Es. + EventsServiceID = "events" // Events. + FirehoseServiceID = "firehose" // Firehose. + FmsServiceID = "fms" // Fms. + GameliftServiceID = "gamelift" // Gamelift. + GlacierServiceID = "glacier" // Glacier. + GlueServiceID = "glue" // Glue. + GreengrassServiceID = "greengrass" // Greengrass. + GuarddutyServiceID = "guardduty" // Guardduty. + HealthServiceID = "health" // Health. + IamServiceID = "iam" // Iam. + ImportexportServiceID = "importexport" // Importexport. + InspectorServiceID = "inspector" // Inspector. + IotServiceID = "iot" // Iot. + IotanalyticsServiceID = "iotanalytics" // Iotanalytics. + KinesisServiceID = "kinesis" // Kinesis. + KinesisanalyticsServiceID = "kinesisanalytics" // Kinesisanalytics. + KinesisvideoServiceID = "kinesisvideo" // Kinesisvideo. + KmsServiceID = "kms" // Kms. + LambdaServiceID = "lambda" // Lambda. + LightsailServiceID = "lightsail" // Lightsail. + LogsServiceID = "logs" // Logs. + MachinelearningServiceID = "machinelearning" // Machinelearning. + MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics. + MediaconvertServiceID = "mediaconvert" // Mediaconvert. + MedialiveServiceID = "medialive" // Medialive. + MediapackageServiceID = "mediapackage" // Mediapackage. + MediastoreServiceID = "mediastore" // Mediastore. + MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace. + MghServiceID = "mgh" // Mgh. + MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics. + ModelsLexServiceID = "models.lex" // ModelsLex. + MonitoringServiceID = "monitoring" // Monitoring. + MturkRequesterServiceID = "mturk-requester" // MturkRequester. + NeptuneServiceID = "neptune" // Neptune. + OpsworksServiceID = "opsworks" // Opsworks. + OpsworksCmServiceID = "opsworks-cm" // OpsworksCm. + OrganizationsServiceID = "organizations" // Organizations. + PinpointServiceID = "pinpoint" // Pinpoint. + PollyServiceID = "polly" // Polly. + RdsServiceID = "rds" // Rds. + RedshiftServiceID = "redshift" // Redshift. + RekognitionServiceID = "rekognition" // Rekognition. + ResourceGroupsServiceID = "resource-groups" // ResourceGroups. + Route53ServiceID = "route53" // Route53. + Route53domainsServiceID = "route53domains" // Route53domains. + RuntimeLexServiceID = "runtime.lex" // RuntimeLex. + RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker. + S3ServiceID = "s3" // S3. + SdbServiceID = "sdb" // Sdb. + SecretsmanagerServiceID = "secretsmanager" // Secretsmanager. + ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo. + ServicecatalogServiceID = "servicecatalog" // Servicecatalog. + ServicediscoveryServiceID = "servicediscovery" // Servicediscovery. + ShieldServiceID = "shield" // Shield. + SmsServiceID = "sms" // Sms. + SnowballServiceID = "snowball" // Snowball. + SnsServiceID = "sns" // Sns. + SqsServiceID = "sqs" // Sqs. + SsmServiceID = "ssm" // Ssm. + StatesServiceID = "states" // States. + StoragegatewayServiceID = "storagegateway" // Storagegateway. + StreamsDynamodbServiceID = "streams.dynamodb" // StreamsDynamodb. + StsServiceID = "sts" // Sts. + SupportServiceID = "support" // Support. + SwfServiceID = "swf" // Swf. + TaggingServiceID = "tagging" // Tagging. + TranslateServiceID = "translate" // Translate. + WafServiceID = "waf" // Waf. + WafRegionalServiceID = "waf-regional" // WafRegional. + WorkdocsServiceID = "workdocs" // Workdocs. + WorkmailServiceID = "workmail" // Workmail. + WorkspacesServiceID = "workspaces" // Workspaces. + XrayServiceID = "xray" // Xray. +) + // DefaultResolver returns an Endpoint resolver that will be able // to resolve endpoints for: AWS Standard, AWS China, and AWS GovCloud (US). // @@ -92,9 +221,6 @@ var awsPartition = partition{ SignatureVersions: []string{"v4"}, }, Regions: regions{ - "ap-east-1": region{ - Description: "Asia Pacific (Hong Kong)", - }, "ap-northeast-1": region{ Description: "Asia Pacific (Tokyo)", }, @@ -116,9 +242,6 @@ var awsPartition = partition{ "eu-central-1": region{ Description: "EU (Frankfurt)", }, - "eu-north-1": region{ - Description: "EU (Stockholm)", - }, "eu-west-1": region{ Description: "EU (Ireland)", }, @@ -154,7 +277,6 @@ var awsPartition = partition{ "acm": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -162,7 +284,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -179,129 +300,17 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, - "api.ecr": service{ - - Endpoints: endpoints{ - "ap-east-1": endpoint{ - Hostname: "api.ecr.ap-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-east-1", - }, - }, - "ap-northeast-1": endpoint{ - Hostname: "api.ecr.ap-northeast-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-1", - }, - }, - "ap-northeast-2": endpoint{ - Hostname: "api.ecr.ap-northeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-2", - }, - }, - "ap-south-1": endpoint{ - Hostname: "api.ecr.ap-south-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-south-1", - }, - }, - "ap-southeast-1": endpoint{ - Hostname: "api.ecr.ap-southeast-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-southeast-1", - }, - }, - "ap-southeast-2": endpoint{ - Hostname: "api.ecr.ap-southeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-southeast-2", - }, - }, - "ca-central-1": endpoint{ - Hostname: "api.ecr.ca-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ca-central-1", - }, - }, - "eu-central-1": endpoint{ - Hostname: "api.ecr.eu-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-central-1", - }, - }, - "eu-north-1": endpoint{ - Hostname: "api.ecr.eu-north-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-north-1", - }, - }, - "eu-west-1": endpoint{ - Hostname: "api.ecr.eu-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-west-1", - }, - }, - "eu-west-2": endpoint{ - Hostname: "api.ecr.eu-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-west-2", - }, - }, - "eu-west-3": endpoint{ - Hostname: "api.ecr.eu-west-3.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-west-3", - }, - }, - "sa-east-1": endpoint{ - Hostname: "api.ecr.sa-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "sa-east-1", - }, - }, - "us-east-1": endpoint{ - Hostname: "api.ecr.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{ - Hostname: "api.ecr.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{ - Hostname: "api.ecr.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{ - Hostname: "api.ecr.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - }, - }, "api.mediatailor": service{ Endpoints: endpoints{ @@ -310,7 +319,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, - "us-west-2": endpoint{}, }, }, "api.pricing": service{ @@ -329,47 +337,17 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "api-fips.sagemaker.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "api-fips.sagemaker.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "api-fips.sagemaker.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "api-fips.sagemaker.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, }, }, "apigateway": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -377,7 +355,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -397,7 +374,6 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -405,7 +381,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -416,24 +391,6 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "appmesh": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "appstream2": service{ Defaults: endpoint{ Protocols: []string{"https"}, @@ -443,31 +400,11 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-west-2": endpoint{}, }, }, - "appsync": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "athena": service{ Endpoints: endpoints{ @@ -476,9 +413,7 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "us-east-1": endpoint{}, @@ -491,7 +426,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -499,7 +433,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -519,42 +452,16 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "backup": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, "batch": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -562,10 +469,8 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -599,29 +504,10 @@ var awsPartition = partition{ }, }, }, - "chime": service{ - PartitionEndpoint: "aws-global", - IsRegionalized: boxedFalse, - Defaults: endpoint{ - SSLCommonName: "service.chime.aws.amazon.com", - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "aws-global": endpoint{ - Hostname: "service.chime.aws.amazon.com", - Protocols: []string{"https"}, - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - }, - }, "cloud9": service{ Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, "ap-southeast-1": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -633,7 +519,6 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -645,7 +530,6 @@ var awsPartition = partition{ "cloudformation": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -653,7 +537,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -700,18 +583,14 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -736,7 +615,6 @@ var awsPartition = partition{ "cloudtrail": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -744,7 +622,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -765,7 +642,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -813,23 +689,16 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "fips": endpoint{ - Hostname: "codecommit-fips.ca-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ca-central-1", - }, - }, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "codedeploy": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -837,39 +706,14 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "codedeploy-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "codedeploy-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "codedeploy-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "codedeploy-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "codepipeline": service{ @@ -917,7 +761,6 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -934,7 +777,6 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -964,24 +806,8 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "comprehendmedical": service{ - - Endpoints: endpoints{ - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-2": endpoint{}, @@ -990,7 +816,6 @@ var awsPartition = partition{ "config": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -998,7 +823,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1015,19 +839,6 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, - "data.mediastore": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "datapipeline": service{ Endpoints: endpoints{ @@ -1038,21 +849,6 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "datasync": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "dax": service{ Endpoints: endpoints{ @@ -1060,7 +856,6 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, @@ -1085,7 +880,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1105,7 +899,6 @@ var awsPartition = partition{ "dms": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1113,7 +906,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1124,59 +916,6 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "docdb": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{ - Hostname: "rds.ap-northeast-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-1", - }, - }, - "ap-northeast-2": endpoint{ - Hostname: "rds.ap-northeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-2", - }, - }, - "ap-southeast-2": endpoint{ - Hostname: "rds.ap-southeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-southeast-2", - }, - }, - "eu-central-1": endpoint{ - Hostname: "rds.eu-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-central-1", - }, - }, - "eu-west-1": endpoint{ - Hostname: "rds.eu-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-west-1", - }, - }, - "us-east-1": endpoint{ - Hostname: "rds.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{ - Hostname: "rds.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-2": endpoint{ - Hostname: "rds.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - }, - }, "ds": service{ Endpoints: endpoints{ @@ -1187,7 +926,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "sa-east-1": endpoint{}, @@ -1202,24 +940,16 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, - "ca-central-1-fips": endpoint{ - Hostname: "dynamodb-fips.ca-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ca-central-1", - }, - }, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "local": endpoint{ Hostname: "localhost:8000", Protocols: []string{"http"}, @@ -1229,33 +959,9 @@ var awsPartition = partition{ }, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "dynamodb-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "dynamodb-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "dynamodb-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "dynamodb-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, }, }, "ec2": service{ @@ -1263,7 +969,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1271,7 +976,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1293,10 +997,29 @@ var awsPartition = partition{ }, }, }, - "ecs": service{ + "ecr": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "ecs": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1304,7 +1027,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1318,7 +1040,6 @@ var awsPartition = partition{ "elasticache": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1326,7 +1047,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1346,7 +1066,6 @@ var awsPartition = partition{ "elasticbeanstalk": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1354,7 +1073,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1370,14 +1088,9 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -1389,7 +1102,6 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1397,7 +1109,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1414,7 +1125,6 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1424,11 +1134,10 @@ var awsPartition = partition{ "eu-central-1": endpoint{ SSLCommonName: "{service}.{region}.{dnsSuffix}", }, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{ SSLCommonName: "{service}.{region}.{dnsSuffix}", }, @@ -1453,12 +1162,9 @@ var awsPartition = partition{ "email": service{ Endpoints: endpoints{ - "ap-south-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "entitlement.marketplace": service{ @@ -1474,7 +1180,6 @@ var awsPartition = partition{ "es": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1482,27 +1187,19 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "fips": endpoint{ - Hostname: "es-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "events": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1510,7 +1207,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1531,7 +1227,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1547,31 +1242,9 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "fsx": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "gamelift": service{ @@ -1598,7 +1271,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1606,11 +1278,9 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -1620,7 +1290,6 @@ var awsPartition = partition{ "glue": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1628,14 +1297,10 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1646,25 +1311,13 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, - "us-east-2": endpoint{}, "us-west-2": endpoint{}, }, }, - "groundstation": service{ - - Endpoints: endpoints{ - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "guardduty": service{ IsRegionalized: boxedTrue, Defaults: endpoint{ @@ -1678,7 +1331,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1731,9 +1383,7 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -1752,87 +1402,26 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, "iotanalytics": service{ Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "iotevents": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "ioteventsdata": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "iotthingsgraph": service{ - Defaults: endpoint{ - CredentialScope: credentialScope{ - Service: "iotthingsgraph", - }, - }, - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "kafka": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, }, }, "kinesis": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1840,7 +1429,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1854,23 +1442,16 @@ var awsPartition = partition{ "kinesisanalytics": service{ Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "kinesisvideo": service{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, @@ -1880,7 +1461,6 @@ var awsPartition = partition{ "kms": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1888,7 +1468,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1902,7 +1481,6 @@ var awsPartition = partition{ "lambda": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1910,29 +1488,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "license-manager": service{ - - Endpoints: endpoints{ - "ap-east-1": endpoint{}, - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1964,7 +1519,6 @@ var awsPartition = partition{ "logs": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -1972,7 +1526,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1996,25 +1549,6 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, - "mediaconnect": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "mediaconvert": service{ Endpoints: endpoints{ @@ -2027,7 +1561,6 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -2044,7 +1577,6 @@ var awsPartition = partition{ "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, @@ -2056,7 +1588,6 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -2064,7 +1595,6 @@ var awsPartition = partition{ "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -2075,7 +1605,6 @@ var awsPartition = partition{ "ap-northeast-2": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-west-2": endpoint{}, @@ -2088,7 +1617,6 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2096,7 +1624,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2136,7 +1663,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2144,7 +1670,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2155,25 +1680,6 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "mq": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "mturk-requester": service{ IsRegionalized: boxedFalse, @@ -2187,60 +1693,12 @@ var awsPartition = partition{ "neptune": service{ Endpoints: endpoints{ - "ap-northeast-1": endpoint{ - Hostname: "rds.ap-northeast-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-1", - }, - }, - "ap-northeast-2": endpoint{ - Hostname: "rds.ap-northeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-northeast-2", - }, - }, - "ap-south-1": endpoint{ - Hostname: "rds.ap-south-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-south-1", - }, - }, - "ap-southeast-1": endpoint{ - Hostname: "rds.ap-southeast-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-southeast-1", - }, - }, - "ap-southeast-2": endpoint{ - Hostname: "rds.ap-southeast-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-southeast-2", - }, - }, - "eu-central-1": endpoint{ - Hostname: "rds.eu-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-central-1", - }, - }, - "eu-north-1": endpoint{ - Hostname: "rds.eu-north-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-north-1", - }, - }, "eu-west-1": endpoint{ Hostname: "rds.eu-west-1.amazonaws.com", CredentialScope: credentialScope{ Region: "eu-west-1", }, }, - "eu-west-2": endpoint{ - Hostname: "rds.eu-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "eu-west-2", - }, - }, "us-east-1": endpoint{ Hostname: "rds.us-east-1.amazonaws.com", CredentialScope: credentialScope{ @@ -2315,12 +1773,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-south-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, + "us-east-1": endpoint{}, }, }, "polly": service{ @@ -2333,7 +1786,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2344,42 +1796,9 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "projects.iot1click": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, - }, - }, - "ram": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "rds": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2387,7 +1806,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2403,7 +1821,6 @@ var awsPartition = partition{ "redshift": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2411,7 +1828,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2426,23 +1842,16 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, "resource-groups": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2450,7 +1859,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2461,15 +1869,6 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "robomaker": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "route53": service{ PartitionEndpoint: "aws-global", IsRegionalized: boxedFalse, @@ -2489,27 +1888,6 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, - "route53resolver": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "runtime.lex": service{ Defaults: endpoint{ CredentialScope: credentialScope{ @@ -2527,41 +1905,12 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "runtime-fips.sagemaker.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "runtime-fips.sagemaker.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "runtime-fips.sagemaker.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "runtime-fips.sagemaker.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, }, }, "s3": service{ @@ -2575,7 +1924,6 @@ var awsPartition = partition{ DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}", }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{ Hostname: "s3.ap-northeast-1.amazonaws.com", SignatureVersions: []string{"s3", "s3v4"}, @@ -2592,7 +1940,6 @@ var awsPartition = partition{ }, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{ Hostname: "s3.eu-west-1.amazonaws.com", SignatureVersions: []string{"s3", "s3v4"}, @@ -2625,157 +1972,6 @@ var awsPartition = partition{ }, }, }, - "s3-control": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - SignatureVersions: []string{"s3v4"}, - - HasDualStack: boxedTrue, - DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}", - }, - Endpoints: endpoints{ - "ap-northeast-1": endpoint{ - Hostname: "s3-control.ap-northeast-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ap-northeast-1", - }, - }, - "ap-northeast-2": endpoint{ - Hostname: "s3-control.ap-northeast-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ap-northeast-2", - }, - }, - "ap-south-1": endpoint{ - Hostname: "s3-control.ap-south-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ap-south-1", - }, - }, - "ap-southeast-1": endpoint{ - Hostname: "s3-control.ap-southeast-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ap-southeast-1", - }, - }, - "ap-southeast-2": endpoint{ - Hostname: "s3-control.ap-southeast-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ap-southeast-2", - }, - }, - "ca-central-1": endpoint{ - Hostname: "s3-control.ca-central-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "ca-central-1", - }, - }, - "eu-central-1": endpoint{ - Hostname: "s3-control.eu-central-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "eu-central-1", - }, - }, - "eu-north-1": endpoint{ - Hostname: "s3-control.eu-north-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "eu-north-1", - }, - }, - "eu-west-1": endpoint{ - Hostname: "s3-control.eu-west-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "eu-west-1", - }, - }, - "eu-west-2": endpoint{ - Hostname: "s3-control.eu-west-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "eu-west-2", - }, - }, - "eu-west-3": endpoint{ - Hostname: "s3-control.eu-west-3.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "eu-west-3", - }, - }, - "sa-east-1": endpoint{ - Hostname: "s3-control.sa-east-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "sa-east-1", - }, - }, - "us-east-1": endpoint{ - Hostname: "s3-control.us-east-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-1-fips": endpoint{ - Hostname: "s3-control-fips.us-east-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{ - Hostname: "s3-control.us-east-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-east-2-fips": endpoint{ - Hostname: "s3-control-fips.us-east-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{ - Hostname: "s3-control.us-west-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-1-fips": endpoint{ - Hostname: "s3-control-fips.us-west-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{ - Hostname: "s3-control.us-west-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - "us-west-2-fips": endpoint{ - Hostname: "s3-control-fips.us-west-2.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - }, - }, "sdb": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -2804,55 +2000,8 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "secretsmanager-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "secretsmanager-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "secretsmanager-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "secretsmanager-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - }, - }, - "securityhub": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -2886,18 +2035,12 @@ var awsPartition = partition{ "eu-central-1": endpoint{ Protocols: []string{"https"}, }, - "eu-north-1": endpoint{ - Protocols: []string{"https"}, - }, "eu-west-1": endpoint{ Protocols: []string{"https"}, }, "eu-west-2": endpoint{ Protocols: []string{"https"}, }, - "eu-west-3": endpoint{ - Protocols: []string{"https"}, - }, "sa-east-1": endpoint{ Protocols: []string{"https"}, }, @@ -2917,51 +2060,6 @@ var awsPartition = partition{ }, "servicecatalog": service{ - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "servicecatalog-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, - "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "servicecatalog-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, - "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "servicecatalog-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, - "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "servicecatalog-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, - }, - }, - "servicediscovery": service{ - Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -2980,10 +2078,20 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "servicediscovery": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "shield": service{ IsRegionalized: boxedFalse, Defaults: endpoint{ - SSLCommonName: "shield.us-east-1.amazonaws.com", + SSLCommonName: "Shield.us-east-1.amazonaws.com", Protocols: []string{"https"}, }, Endpoints: endpoints{ @@ -2993,7 +2101,6 @@ var awsPartition = partition{ "sms": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3001,7 +2108,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3036,7 +2142,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3044,7 +2149,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3061,7 +2165,6 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3069,7 +2172,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3109,7 +2211,6 @@ var awsPartition = partition{ "ssm": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3117,7 +2218,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3131,7 +2231,6 @@ var awsPartition = partition{ "states": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3139,11 +2238,8 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -3160,7 +2256,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3185,17 +2280,10 @@ var awsPartition = partition{ "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, - "ca-central-1-fips": endpoint{ - Hostname: "dynamodb-fips.ca-central-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ca-central-1", - }, - }, - "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "local": endpoint{ Hostname: "localhost:8000", Protocols: []string{"http"}, @@ -3205,33 +2293,9 @@ var awsPartition = partition{ }, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "dynamodb-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "dynamodb-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, "us-west-1": endpoint{}, - "us-west-1-fips": endpoint{ - Hostname: "dynamodb-fips.us-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-1", - }, - }, "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "dynamodb-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, }, }, "sts": service{ @@ -3243,12 +2307,6 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "ap-east-1": endpoint{ - Hostname: "sts.ap-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "ap-east-1", - }, - }, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{ Hostname: "sts.ap-northeast-2.amazonaws.com", @@ -3262,7 +2320,6 @@ var awsPartition = partition{ "aws-global": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3298,21 +2355,14 @@ var awsPartition = partition{ }, }, "support": service{ - PartitionEndpoint: "aws-global", Endpoints: endpoints{ - "aws-global": endpoint{ - Hostname: "support.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, + "us-east-1": endpoint{}, }, }, "swf": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3320,7 +2370,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3334,7 +2383,6 @@ var awsPartition = partition{ "tagging": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3342,7 +2390,6 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3353,58 +2400,15 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "transfer": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "translate": service{ Defaults: endpoint{ Protocols: []string{"https"}, }, Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-1-fips": endpoint{ - Hostname: "translate-fips.us-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-1", - }, - }, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, "us-east-2": endpoint{}, - "us-east-2-fips": endpoint{ - Hostname: "translate-fips.us-east-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-east-2", - }, - }, "us-west-2": endpoint{}, - "us-west-2-fips": endpoint{ - Hostname: "translate-fips.us-west-2.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-west-2", - }, - }, }, }, "waf": service{ @@ -3424,13 +2428,9 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -3477,7 +2477,6 @@ var awsPartition = partition{ "xray": service{ Endpoints: endpoints{ - "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -3485,10 +2484,8 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, - "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -3528,23 +2525,6 @@ var awscnPartition = partition{ }, }, Services: services{ - "api.ecr": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{ - Hostname: "api.ecr.cn-north-1.amazonaws.com.cn", - CredentialScope: credentialScope{ - Region: "cn-north-1", - }, - }, - "cn-northwest-1": endpoint{ - Hostname: "api.ecr.cn-northwest-1.amazonaws.com.cn", - CredentialScope: credentialScope{ - Region: "cn-northwest-1", - }, - }, - }, - }, "apigateway": service{ Endpoints: endpoints{ @@ -3581,20 +2561,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "cloudfront": service{ - PartitionEndpoint: "aws-cn-global", - IsRegionalized: boxedFalse, - - Endpoints: endpoints{ - "aws-cn-global": endpoint{ - Hostname: "cloudfront.cn-northwest-1.amazonaws.com.cn", - Protocols: []string{"http", "https"}, - CredentialScope: credentialScope{ - Region: "cn-northwest-1", - }, - }, - }, - }, "cloudtrail": service{ Endpoints: endpoints{ @@ -3602,13 +2568,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "codebuild": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "codedeploy": service{ Endpoints: endpoints{ @@ -3636,13 +2595,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "dms": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "ds": service{ Endpoints: endpoints{ @@ -3679,6 +2631,13 @@ var awscnPartition = partition{ }, }, }, + "ecr": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "ecs": service{ Endpoints: endpoints{ @@ -3721,7 +2680,6 @@ var awscnPartition = partition{ "es": service{ Endpoints: endpoints{ - "cn-north-1": endpoint{}, "cn-northwest-1": endpoint{}, }, }, @@ -3732,19 +2690,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "firehose": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, - "gamelift": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - }, - }, "glacier": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -3754,15 +2699,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "greengrass": service{ - IsRegionalized: boxedTrue, - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - }, - }, "iam": service{ PartitionEndpoint: "aws-cn-global", IsRegionalized: boxedFalse, @@ -3793,13 +2729,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "kms": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "lambda": service{ Endpoints: endpoints{ @@ -3807,13 +2736,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "license-manager": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "logs": service{ Endpoints: endpoints{ @@ -3821,17 +2743,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "mediaconvert": service{ - - Endpoints: endpoints{ - "cn-northwest-1": endpoint{ - Hostname: "subscribe.mediaconvert.cn-northwest-1.amazonaws.com.cn", - CredentialScope: credentialScope{ - Region: "cn-northwest-1", - }, - }, - }, - }, "monitoring": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -3841,12 +2752,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "polly": service{ - - Endpoints: endpoints{ - "cn-northwest-1": endpoint{}, - }, - }, "rds": service{ Endpoints: endpoints{ @@ -3871,28 +2776,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "s3-control": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - SignatureVersions: []string{"s3v4"}, - }, - Endpoints: endpoints{ - "cn-north-1": endpoint{ - Hostname: "s3-control.cn-north-1.amazonaws.com.cn", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "cn-north-1", - }, - }, - "cn-northwest-1": endpoint{ - Hostname: "s3-control.cn-northwest-1.amazonaws.com.cn", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "cn-northwest-1", - }, - }, - }, - }, "sms": service{ Endpoints: endpoints{ @@ -3932,13 +2815,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "states": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "storagegateway": service{ Endpoints: endpoints{ @@ -3964,18 +2840,6 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, - "support": service{ - PartitionEndpoint: "aws-cn-global", - - Endpoints: endpoints{ - "aws-cn-global": endpoint{ - Hostname: "support.cn-north-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "cn-north-1", - }, - }, - }, - }, "swf": service{ Endpoints: endpoints{ @@ -4014,9 +2878,6 @@ var awsusgovPartition = partition{ SignatureVersions: []string{"v4"}, }, Regions: regions{ - "us-gov-east-1": region{ - Description: "AWS GovCloud (US-East)", - }, "us-gov-west-1": region{ Description: "AWS GovCloud (US)", }, @@ -4024,39 +2885,6 @@ var awsusgovPartition = partition{ Services: services{ "acm": service{ - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "acm-pca": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "api.ecr": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{ - Hostname: "api.ecr.us-gov-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, - "us-gov-west-1": endpoint{ - Hostname: "api.ecr.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, - "api.sagemaker": service{ - Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -4064,48 +2892,20 @@ var awsusgovPartition = partition{ "apigateway": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "application-autoscaling": service{ - Defaults: endpoint{ - Hostname: "autoscaling.{region}.amazonaws.com", - CredentialScope: credentialScope{ - Service: "application-autoscaling", - }, - }, - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "athena": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "autoscaling": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, }, }, - "clouddirectory": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, "cloudformation": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4122,67 +2922,23 @@ var awsusgovPartition = partition{ }, }, Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "cloudtrail": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "codebuild": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "codecommit": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "codedeploy": service{ - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-east-1-fips": endpoint{ - Hostname: "codedeploy-fips.us-gov-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, - "us-gov-west-1": endpoint{}, - "us-gov-west-1-fips": endpoint{ - Hostname: "codedeploy-fips.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, - "comprehend": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - }, Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, }, "config": service{ - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "datasync": service{ - Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -4190,34 +2946,18 @@ var awsusgovPartition = partition{ "directconnect": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "dms": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "ds": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "dynamodb": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-east-1-fips": endpoint{ - Hostname: "dynamodb.us-gov-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, "us-gov-west-1": endpoint{}, "us-gov-west-1-fips": endpoint{ Hostname: "dynamodb.us-gov-west-1.amazonaws.com", @@ -4230,7 +2970,6 @@ var awsusgovPartition = partition{ "ec2": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4245,10 +2984,15 @@ var awsusgovPartition = partition{ }, }, }, + "ecr": service{ + + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "ecs": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4261,19 +3005,11 @@ var awsusgovPartition = partition{ Region: "us-gov-west-1", }, }, - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "elasticbeanstalk": service{ - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "elasticfilesystem": service{ - Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -4281,7 +3017,6 @@ var awsusgovPartition = partition{ "elasticloadbalancing": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, @@ -4290,7 +3025,6 @@ var awsusgovPartition = partition{ "elasticmapreduce": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"https"}, }, @@ -4299,64 +3033,23 @@ var awsusgovPartition = partition{ "es": service{ Endpoints: endpoints{ - "fips": endpoint{ - Hostname: "es-fips.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "events": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "firehose": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "glacier": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, }, }, - "glue": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "greengrass": service{ - IsRegionalized: boxedTrue, - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, - "guardduty": service{ - IsRegionalized: boxedTrue, - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, "iam": service{ PartitionEndpoint: "aws-us-gov-global", IsRegionalized: boxedFalse, @@ -4373,7 +3066,6 @@ var awsusgovPartition = partition{ "inspector": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4390,46 +3082,23 @@ var awsusgovPartition = partition{ "kinesis": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "kms": service{ Endpoints: endpoints{ - "ProdFips": endpoint{ - Hostname: "kms-fips.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "lambda": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "license-manager": service{ - - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "logs": service{ - Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, - }, - }, - "mediaconvert": service{ - Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -4447,46 +3116,24 @@ var awsusgovPartition = partition{ "monitoring": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, - "organizations": service{ - PartitionEndpoint: "aws-us-gov-global", - IsRegionalized: boxedFalse, - - Endpoints: endpoints{ - "aws-us-gov-global": endpoint{ - Hostname: "organizations.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, "polly": service{ Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, }, - "ram": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, "rds": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "redshift": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4496,12 +3143,6 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, - "runtime.sagemaker": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, "s3": service{ Defaults: endpoint{ SignatureVersions: []string{"s3", "s3v4"}, @@ -4513,92 +3154,27 @@ var awsusgovPartition = partition{ Region: "us-gov-west-1", }, }, - "us-gov-east-1": endpoint{ - Hostname: "s3.us-gov-east-1.amazonaws.com", - Protocols: []string{"http", "https"}, - }, "us-gov-west-1": endpoint{ Hostname: "s3.us-gov-west-1.amazonaws.com", Protocols: []string{"http", "https"}, }, }, }, - "s3-control": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - SignatureVersions: []string{"s3v4"}, - }, - Endpoints: endpoints{ - "us-gov-east-1": endpoint{ - Hostname: "s3-control.us-gov-east-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, - "us-gov-east-1-fips": endpoint{ - Hostname: "s3-control-fips.us-gov-east-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, - "us-gov-west-1": endpoint{ - Hostname: "s3-control.us-gov-west-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - "us-gov-west-1-fips": endpoint{ - Hostname: "s3-control-fips.us-gov-west-1.amazonaws.com", - SignatureVersions: []string{"s3v4"}, - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, - "secretsmanager": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - "us-gov-west-1-fips": endpoint{ - Hostname: "secretsmanager-fips.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, - "serverlessrepo": service{ - Defaults: endpoint{ - Protocols: []string{"https"}, - }, - Endpoints: endpoints{ - "us-gov-west-1": endpoint{ - Protocols: []string{"https"}, - }, - }, - }, "sms": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "snowball": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "sns": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, @@ -4607,7 +3183,6 @@ var awsusgovPartition = partition{ "sqs": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ SSLCommonName: "{region}.queue.{dnsSuffix}", Protocols: []string{"http", "https"}, @@ -4617,14 +3192,12 @@ var awsusgovPartition = partition{ "ssm": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "states": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4641,13 +3214,6 @@ var awsusgovPartition = partition{ }, }, Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-east-1-fips": endpoint{ - Hostname: "dynamodb.us-gov-east-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-east-1", - }, - }, "us-gov-west-1": endpoint{}, "us-gov-west-1-fips": endpoint{ Hostname: "dynamodb.us-gov-west-1.amazonaws.com", @@ -4660,21 +3226,18 @@ var awsusgovPartition = partition{ "sts": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "swf": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "tagging": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -4682,24 +3245,6 @@ var awsusgovPartition = partition{ Defaults: endpoint{ Protocols: []string{"https"}, }, - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - "us-gov-west-1-fips": endpoint{ - Hostname: "translate-fips.us-gov-west-1.amazonaws.com", - CredentialScope: credentialScope{ - Region: "us-gov-west-1", - }, - }, - }, - }, - "waf-regional": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, - "workspaces": service{ - Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go deleted file mode 100644 index ca8fc828e..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go +++ /dev/null @@ -1,141 +0,0 @@ -package endpoints - -// Service identifiers -// -// Deprecated: Use client package's EndpointsID value instead of these -// ServiceIDs. These IDs are not maintained, and are out of date. -const ( - A4bServiceID = "a4b" // A4b. - AcmServiceID = "acm" // Acm. - AcmPcaServiceID = "acm-pca" // AcmPca. - ApiMediatailorServiceID = "api.mediatailor" // ApiMediatailor. - ApiPricingServiceID = "api.pricing" // ApiPricing. - ApiSagemakerServiceID = "api.sagemaker" // ApiSagemaker. - ApigatewayServiceID = "apigateway" // Apigateway. - ApplicationAutoscalingServiceID = "application-autoscaling" // ApplicationAutoscaling. - Appstream2ServiceID = "appstream2" // Appstream2. - AppsyncServiceID = "appsync" // Appsync. - AthenaServiceID = "athena" // Athena. - AutoscalingServiceID = "autoscaling" // Autoscaling. - AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans. - BatchServiceID = "batch" // Batch. - BudgetsServiceID = "budgets" // Budgets. - CeServiceID = "ce" // Ce. - ChimeServiceID = "chime" // Chime. - Cloud9ServiceID = "cloud9" // Cloud9. - ClouddirectoryServiceID = "clouddirectory" // Clouddirectory. - CloudformationServiceID = "cloudformation" // Cloudformation. - CloudfrontServiceID = "cloudfront" // Cloudfront. - CloudhsmServiceID = "cloudhsm" // Cloudhsm. - Cloudhsmv2ServiceID = "cloudhsmv2" // Cloudhsmv2. - CloudsearchServiceID = "cloudsearch" // Cloudsearch. - CloudtrailServiceID = "cloudtrail" // Cloudtrail. - CodebuildServiceID = "codebuild" // Codebuild. - CodecommitServiceID = "codecommit" // Codecommit. - CodedeployServiceID = "codedeploy" // Codedeploy. - CodepipelineServiceID = "codepipeline" // Codepipeline. - CodestarServiceID = "codestar" // Codestar. - CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity. - CognitoIdpServiceID = "cognito-idp" // CognitoIdp. - CognitoSyncServiceID = "cognito-sync" // CognitoSync. - ComprehendServiceID = "comprehend" // Comprehend. - ConfigServiceID = "config" // Config. - CurServiceID = "cur" // Cur. - DatapipelineServiceID = "datapipeline" // Datapipeline. - DaxServiceID = "dax" // Dax. - DevicefarmServiceID = "devicefarm" // Devicefarm. - DirectconnectServiceID = "directconnect" // Directconnect. - DiscoveryServiceID = "discovery" // Discovery. - DmsServiceID = "dms" // Dms. - DsServiceID = "ds" // Ds. - DynamodbServiceID = "dynamodb" // Dynamodb. - Ec2ServiceID = "ec2" // Ec2. - Ec2metadataServiceID = "ec2metadata" // Ec2metadata. - EcrServiceID = "ecr" // Ecr. - EcsServiceID = "ecs" // Ecs. - ElasticacheServiceID = "elasticache" // Elasticache. - ElasticbeanstalkServiceID = "elasticbeanstalk" // Elasticbeanstalk. - ElasticfilesystemServiceID = "elasticfilesystem" // Elasticfilesystem. - ElasticloadbalancingServiceID = "elasticloadbalancing" // Elasticloadbalancing. - ElasticmapreduceServiceID = "elasticmapreduce" // Elasticmapreduce. - ElastictranscoderServiceID = "elastictranscoder" // Elastictranscoder. - EmailServiceID = "email" // Email. - EntitlementMarketplaceServiceID = "entitlement.marketplace" // EntitlementMarketplace. - EsServiceID = "es" // Es. - EventsServiceID = "events" // Events. - FirehoseServiceID = "firehose" // Firehose. - FmsServiceID = "fms" // Fms. - GameliftServiceID = "gamelift" // Gamelift. - GlacierServiceID = "glacier" // Glacier. - GlueServiceID = "glue" // Glue. - GreengrassServiceID = "greengrass" // Greengrass. - GuarddutyServiceID = "guardduty" // Guardduty. - HealthServiceID = "health" // Health. - IamServiceID = "iam" // Iam. - ImportexportServiceID = "importexport" // Importexport. - InspectorServiceID = "inspector" // Inspector. - IotServiceID = "iot" // Iot. - IotanalyticsServiceID = "iotanalytics" // Iotanalytics. - KinesisServiceID = "kinesis" // Kinesis. - KinesisanalyticsServiceID = "kinesisanalytics" // Kinesisanalytics. - KinesisvideoServiceID = "kinesisvideo" // Kinesisvideo. - KmsServiceID = "kms" // Kms. - LambdaServiceID = "lambda" // Lambda. - LightsailServiceID = "lightsail" // Lightsail. - LogsServiceID = "logs" // Logs. - MachinelearningServiceID = "machinelearning" // Machinelearning. - MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics. - MediaconvertServiceID = "mediaconvert" // Mediaconvert. - MedialiveServiceID = "medialive" // Medialive. - MediapackageServiceID = "mediapackage" // Mediapackage. - MediastoreServiceID = "mediastore" // Mediastore. - MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace. - MghServiceID = "mgh" // Mgh. - MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics. - ModelsLexServiceID = "models.lex" // ModelsLex. - MonitoringServiceID = "monitoring" // Monitoring. - MturkRequesterServiceID = "mturk-requester" // MturkRequester. - NeptuneServiceID = "neptune" // Neptune. - OpsworksServiceID = "opsworks" // Opsworks. - OpsworksCmServiceID = "opsworks-cm" // OpsworksCm. - OrganizationsServiceID = "organizations" // Organizations. - PinpointServiceID = "pinpoint" // Pinpoint. - PollyServiceID = "polly" // Polly. - RdsServiceID = "rds" // Rds. - RedshiftServiceID = "redshift" // Redshift. - RekognitionServiceID = "rekognition" // Rekognition. - ResourceGroupsServiceID = "resource-groups" // ResourceGroups. - Route53ServiceID = "route53" // Route53. - Route53domainsServiceID = "route53domains" // Route53domains. - RuntimeLexServiceID = "runtime.lex" // RuntimeLex. - RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker. - S3ServiceID = "s3" // S3. - S3ControlServiceID = "s3-control" // S3Control. - SagemakerServiceID = "api.sagemaker" // Sagemaker. - SdbServiceID = "sdb" // Sdb. - SecretsmanagerServiceID = "secretsmanager" // Secretsmanager. - ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo. - ServicecatalogServiceID = "servicecatalog" // Servicecatalog. - ServicediscoveryServiceID = "servicediscovery" // Servicediscovery. - ShieldServiceID = "shield" // Shield. - SmsServiceID = "sms" // Sms. - SnowballServiceID = "snowball" // Snowball. - SnsServiceID = "sns" // Sns. - SqsServiceID = "sqs" // Sqs. - SsmServiceID = "ssm" // Ssm. - StatesServiceID = "states" // States. - StoragegatewayServiceID = "storagegateway" // Storagegateway. - StreamsDynamodbServiceID = "streams.dynamodb" // StreamsDynamodb. - StsServiceID = "sts" // Sts. - SupportServiceID = "support" // Support. - SwfServiceID = "swf" // Swf. - TaggingServiceID = "tagging" // Tagging. - TransferServiceID = "transfer" // Transfer. - TranslateServiceID = "translate" // Translate. - WafServiceID = "waf" // Waf. - WafRegionalServiceID = "waf-regional" // WafRegional. - WorkdocsServiceID = "workdocs" // Workdocs. - WorkmailServiceID = "workmail" // Workmail. - WorkspacesServiceID = "workspaces" // Workspaces. - XrayServiceID = "xray" // Xray. -) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go index f82babf6f..e29c09512 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go @@ -35,7 +35,7 @@ type Options struct { // // If resolving an endpoint on the partition list the provided region will // be used to determine which partition's domain name pattern to the service - // endpoint ID with. If both the service and region are unknown and resolving + // endpoint ID with. If both the service and region are unkonwn and resolving // the endpoint on partition list an UnknownEndpointError error will be returned. // // If resolving and endpoint on a partition specific resolver that partition's diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go index 0fdfcc56e..05e92df22 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go @@ -16,10 +16,6 @@ import ( type CodeGenOptions struct { // Options for how the model will be decoded. DecodeModelOptions DecodeModelOptions - - // Disables code generation of the service endpoint prefix IDs defined in - // the model. - DisableGenerateServiceIDs bool } // Set combines all of the option functions together @@ -43,16 +39,8 @@ func CodeGenModel(modelFile io.Reader, outFile io.Writer, optFns ...func(*CodeGe return err } - v := struct { - Resolver - CodeGenOptions - }{ - Resolver: resolver, - CodeGenOptions: opts, - } - tmpl := template.Must(template.New("tmpl").Funcs(funcMap).Parse(v3Tmpl)) - if err := tmpl.ExecuteTemplate(outFile, "defaults", v); err != nil { + if err := tmpl.ExecuteTemplate(outFile, "defaults", resolver); err != nil { return fmt.Errorf("failed to execute template, %v", err) } @@ -178,17 +166,15 @@ import ( "regexp" ) - {{ template "partition consts" $.Resolver }} + {{ template "partition consts" . }} - {{ range $_, $partition := $.Resolver }} + {{ range $_, $partition := . }} {{ template "partition region consts" $partition }} {{ end }} - {{ if not $.DisableGenerateServiceIDs -}} - {{ template "service consts" $.Resolver }} - {{- end }} + {{ template "service consts" . }} - {{ template "endpoint resolvers" $.Resolver }} + {{ template "endpoint resolvers" . }} {{- end }} {{ define "partition consts" }} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/errors.go b/vendor/github.com/aws/aws-sdk-go/aws/errors.go index fa06f7a8f..576636168 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/errors.go @@ -5,9 +5,13 @@ import "github.com/aws/aws-sdk-go/aws/awserr" var ( // ErrMissingRegion is an error that is returned if region configuration is // not found. + // + // @readonly ErrMissingRegion = awserr.New("MissingRegion", "could not find region configuration", nil) // ErrMissingEndpoint is an error that is returned if an endpoint cannot be // resolved for a service. + // + // @readonly ErrMissingEndpoint = awserr.New("MissingEndpoint", "'Endpoint' configuration is required for this service", nil) ) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go index d9b37f4d3..271da432c 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go @@ -1,17 +1,18 @@ +// +build !appengine,!plan9 + package request import ( - "strings" + "net" + "os" + "syscall" ) func isErrConnectionReset(err error) bool { - if strings.Contains(err.Error(), "read: connection reset") { - return false - } - - if strings.Contains(err.Error(), "connection reset") || - strings.Contains(err.Error(), "broken pipe") { - return true + if opErr, ok := err.(*net.OpError); ok { + if sysErr, ok := opErr.Err.(*os.SyscallError); ok { + return sysErr.Err == syscall.ECONNRESET + } } return false diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go new file mode 100644 index 000000000..daf9eca43 --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error_other.go @@ -0,0 +1,11 @@ +// +build appengine plan9 + +package request + +import ( + "strings" +) + +func isErrConnectionReset(err error) bool { + return strings.Contains(err.Error(), "connection reset") +} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go index 627ec722c..605a72d3c 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go @@ -19,7 +19,6 @@ type Handlers struct { UnmarshalError HandlerList Retry HandlerList AfterRetry HandlerList - CompleteAttempt HandlerList Complete HandlerList } @@ -37,7 +36,6 @@ func (h *Handlers) Copy() Handlers { UnmarshalMeta: h.UnmarshalMeta.copy(), Retry: h.Retry.copy(), AfterRetry: h.AfterRetry.copy(), - CompleteAttempt: h.CompleteAttempt.copy(), Complete: h.Complete.copy(), } } @@ -55,55 +53,9 @@ func (h *Handlers) Clear() { h.ValidateResponse.Clear() h.Retry.Clear() h.AfterRetry.Clear() - h.CompleteAttempt.Clear() h.Complete.Clear() } -// IsEmpty returns if there are no handlers in any of the handlerlists. -func (h *Handlers) IsEmpty() bool { - if h.Validate.Len() != 0 { - return false - } - if h.Build.Len() != 0 { - return false - } - if h.Send.Len() != 0 { - return false - } - if h.Sign.Len() != 0 { - return false - } - if h.Unmarshal.Len() != 0 { - return false - } - if h.UnmarshalStream.Len() != 0 { - return false - } - if h.UnmarshalMeta.Len() != 0 { - return false - } - if h.UnmarshalError.Len() != 0 { - return false - } - if h.ValidateResponse.Len() != 0 { - return false - } - if h.Retry.Len() != 0 { - return false - } - if h.AfterRetry.Len() != 0 { - return false - } - if h.CompleteAttempt.Len() != 0 { - return false - } - if h.Complete.Len() != 0 { - return false - } - - return true -} - // A HandlerListRunItem represents an entry in the HandlerList which // is being run. type HandlerListRunItem struct { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go index 2f0c4a90e..75f0fe077 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/request.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/request.go @@ -122,6 +122,7 @@ func New(cfg aws.Config, clientInfo metadata.ClientInfo, handlers Handlers, Handlers: handlers.Copy(), Retryer: retryer, + AttemptTime: time.Now(), Time: time.Now(), ExpireTime: 0, Operation: operation, @@ -232,10 +233,6 @@ func (r *Request) WillRetry() bool { return r.Error != nil && aws.BoolValue(r.Retryable) && r.RetryCount < r.MaxRetries() } -func fmtAttemptCount(retryCount, maxRetries int) string { - return fmt.Sprintf("attempt %v/%v", retryCount, maxRetries) -} - // ParamsFilled returns if the request's parameters have been populated // and the parameters are valid. False is returned if no parameters are // provided or invalid. @@ -269,9 +266,7 @@ func (r *Request) SetReaderBody(reader io.ReadSeeker) { } // Presign returns the request's signed URL. Error will be returned -// if the signing fails. The expire parameter is only used for presigned Amazon -// S3 API requests. All other AWS services will use a fixed expiration -// time of 15 minutes. +// if the signing fails. // // It is invalid to create a presigned URL with a expire duration 0 or less. An // error is returned if expire duration is 0 or less. @@ -288,9 +283,7 @@ func (r *Request) Presign(expire time.Duration) (string, error) { } // PresignRequest behaves just like presign, with the addition of returning a -// set of headers that were signed. The expire parameter is only used for -// presigned Amazon S3 API requests. All other AWS services will use a fixed -// expiration time of 15 minutes. +// set of headers that were signed. // // It is invalid to create a presigned URL with a expire duration 0 or less. An // error is returned if expire duration is 0 or less. @@ -335,17 +328,16 @@ func getPresignedURL(r *Request, expire time.Duration) (string, http.Header, err return r.HTTPRequest.URL.String(), r.SignedHeaderVals, nil } -const ( - willRetry = "will retry" - notRetrying = "not retrying" - retryCount = "retry %v/%v" -) - -func debugLogReqError(r *Request, stage, retryStr string, err error) { +func debugLogReqError(r *Request, stage string, retrying bool, err error) { if !r.Config.LogLevel.Matches(aws.LogDebugWithRequestErrors) { return } + retryStr := "not retrying" + if retrying { + retryStr = "will retry" + } + r.Config.Logger.Log(fmt.Sprintf("DEBUG: %s %s/%s failed, %s, error %v", stage, r.ClientInfo.ServiceName, r.Operation.Name, retryStr, err)) } @@ -364,12 +356,12 @@ func (r *Request) Build() error { if !r.built { r.Handlers.Validate.Run(r) if r.Error != nil { - debugLogReqError(r, "Validate Request", notRetrying, r.Error) + debugLogReqError(r, "Validate Request", false, r.Error) return r.Error } r.Handlers.Build.Run(r) if r.Error != nil { - debugLogReqError(r, "Build Request", notRetrying, r.Error) + debugLogReqError(r, "Build Request", false, r.Error) return r.Error } r.built = true @@ -385,7 +377,7 @@ func (r *Request) Build() error { func (r *Request) Sign() error { r.Build() if r.Error != nil { - debugLogReqError(r, "Build Request", notRetrying, r.Error) + debugLogReqError(r, "Build Request", false, r.Error) return r.Error } @@ -470,84 +462,80 @@ func (r *Request) Send() error { r.Handlers.Complete.Run(r) }() - if err := r.Error; err != nil { - return err - } - for { - r.Error = nil r.AttemptTime = time.Now() + if aws.BoolValue(r.Retryable) { + if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) { + r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d", + r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount)) + } - if err := r.Sign(); err != nil { - debugLogReqError(r, "Sign Request", notRetrying, err) - return err + // The previous http.Request will have a reference to the r.Body + // and the HTTP Client's Transport may still be reading from + // the request's body even though the Client's Do returned. + r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil) + r.ResetBody() + + // Closing response body to ensure that no response body is leaked + // between retry attempts. + if r.HTTPResponse != nil && r.HTTPResponse.Body != nil { + r.HTTPResponse.Body.Close() + } } - if err := r.sendRequest(); err == nil { - return nil - } else if !shouldRetryError(r.Error) { - return err - } else { - r.Handlers.Retry.Run(r) - r.Handlers.AfterRetry.Run(r) + r.Sign() + if r.Error != nil { + return r.Error + } - if r.Error != nil || !aws.BoolValue(r.Retryable) { + r.Retryable = nil + + r.Handlers.Send.Run(r) + if r.Error != nil { + if !shouldRetryCancel(r) { return r.Error } - r.prepareRetry() + err := r.Error + r.Handlers.Retry.Run(r) + r.Handlers.AfterRetry.Run(r) + if r.Error != nil { + debugLogReqError(r, "Send Request", false, err) + return r.Error + } + debugLogReqError(r, "Send Request", true, err) continue } - } -} + r.Handlers.UnmarshalMeta.Run(r) + r.Handlers.ValidateResponse.Run(r) + if r.Error != nil { + r.Handlers.UnmarshalError.Run(r) + err := r.Error -func (r *Request) prepareRetry() { - if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) { - r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d", - r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount)) - } + r.Handlers.Retry.Run(r) + r.Handlers.AfterRetry.Run(r) + if r.Error != nil { + debugLogReqError(r, "Validate Response", false, err) + return r.Error + } + debugLogReqError(r, "Validate Response", true, err) + continue + } - // The previous http.Request will have a reference to the r.Body - // and the HTTP Client's Transport may still be reading from - // the request's body even though the Client's Do returned. - r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil) - r.ResetBody() + r.Handlers.Unmarshal.Run(r) + if r.Error != nil { + err := r.Error + r.Handlers.Retry.Run(r) + r.Handlers.AfterRetry.Run(r) + if r.Error != nil { + debugLogReqError(r, "Unmarshal Response", false, err) + return r.Error + } + debugLogReqError(r, "Unmarshal Response", true, err) + continue + } - // Closing response body to ensure that no response body is leaked - // between retry attempts. - if r.HTTPResponse != nil && r.HTTPResponse.Body != nil { - r.HTTPResponse.Body.Close() - } -} - -func (r *Request) sendRequest() (sendErr error) { - defer r.Handlers.CompleteAttempt.Run(r) - - r.Retryable = nil - r.Handlers.Send.Run(r) - if r.Error != nil { - debugLogReqError(r, "Send Request", - fmtAttemptCount(r.RetryCount, r.MaxRetries()), - r.Error) - return r.Error - } - - r.Handlers.UnmarshalMeta.Run(r) - r.Handlers.ValidateResponse.Run(r) - if r.Error != nil { - r.Handlers.UnmarshalError.Run(r) - debugLogReqError(r, "Validate Response", - fmtAttemptCount(r.RetryCount, r.MaxRetries()), - r.Error) - return r.Error - } - - r.Handlers.Unmarshal.Run(r) - if r.Error != nil { - debugLogReqError(r, "Unmarshal Response", - fmtAttemptCount(r.RetryCount, r.MaxRetries()), - r.Error) - return r.Error + break } return nil @@ -573,49 +561,30 @@ func AddToUserAgent(r *Request, s string) { r.HTTPRequest.Header.Set("User-Agent", s) } -type temporary interface { - Temporary() bool -} - -func shouldRetryError(origErr error) bool { - switch err := origErr.(type) { - case awserr.Error: - if err.Code() == CanceledErrorCode { +func shouldRetryCancel(r *Request) bool { + awsErr, ok := r.Error.(awserr.Error) + timeoutErr := false + errStr := r.Error.Error() + if ok { + if awsErr.Code() == CanceledErrorCode { return false } - return shouldRetryError(err.OrigErr()) - case *url.Error: - if strings.Contains(err.Error(), "connection refused") { - // Refused connections should be retried as the service may not yet - // be running on the port. Go TCP dial considers refused - // connections as not temporary. - return true + err := awsErr.OrigErr() + netErr, netOK := err.(net.Error) + timeoutErr = netOK && netErr.Temporary() + if urlErr, ok := err.(*url.Error); !timeoutErr && ok { + errStr = urlErr.Err.Error() } - // *url.Error only implements Temporary after golang 1.6 but since - // url.Error only wraps the error: - return shouldRetryError(err.Err) - case temporary: - if netErr, ok := err.(*net.OpError); ok && netErr.Op == "dial" { - return true - } - // If the error is temporary, we want to allow continuation of the - // retry process - return err.Temporary() || isErrConnectionReset(origErr) - case nil: - // `awserr.Error.OrigErr()` can be nil, meaning there was an error but - // because we don't know the cause, it is marked as retryable. See - // TestRequest4xxUnretryable for an example. - return true - default: - switch err.Error() { - case "net/http: request canceled", - "net/http: request canceled while waiting for connection": - // known 1.5 error case when an http request is cancelled - return false - } - // here we don't know the error; so we allow a retry. - return true } + + // There can be two types of canceled errors here. + // The first being a net.Error and the other being an error. + // If the request was timed out, we want to continue the retry + // process. Otherwise, return the canceled error. + return timeoutErr || + (errStr != "net/http: request canceled" && + errStr != "net/http: request canceled while waiting for connection") + } // SanitizeHostForHeader removes default port from host and updates request.Host diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go b/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go index d0aa54c6d..7d5270298 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go @@ -38,10 +38,8 @@ var throttleCodes = map[string]struct{}{ "ThrottlingException": {}, "RequestLimitExceeded": {}, "RequestThrottled": {}, - "RequestThrottledException": {}, "TooManyRequestsException": {}, // Lambda functions "PriorRequestNotComplete": {}, // Route53 - "TransactionInProgressException": {}, } // credsExpiredCodes is a collection of error codes which signify the credentials diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go b/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go index 8630683f3..401246228 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go @@ -17,12 +17,6 @@ const ( ParamMinValueErrCode = "ParamMinValueError" // ParamMinLenErrCode is the error code for fields without enough elements. ParamMinLenErrCode = "ParamMinLenError" - // ParamMaxLenErrCode is the error code for value being too long. - ParamMaxLenErrCode = "ParamMaxLenError" - - // ParamFormatErrCode is the error code for a field with invalid - // format or characters. - ParamFormatErrCode = "ParamFormatInvalidError" ) // Validator provides a way for types to perform validation logic on their @@ -238,49 +232,3 @@ func NewErrParamMinLen(field string, min int) *ErrParamMinLen { func (e *ErrParamMinLen) MinLen() int { return e.min } - -// An ErrParamMaxLen represents a maximum length parameter error. -type ErrParamMaxLen struct { - errInvalidParam - max int -} - -// NewErrParamMaxLen creates a new maximum length parameter error. -func NewErrParamMaxLen(field string, max int, value string) *ErrParamMaxLen { - return &ErrParamMaxLen{ - errInvalidParam: errInvalidParam{ - code: ParamMaxLenErrCode, - field: field, - msg: fmt.Sprintf("maximum size of %v, %v", max, value), - }, - max: max, - } -} - -// MaxLen returns the field's required minimum length. -func (e *ErrParamMaxLen) MaxLen() int { - return e.max -} - -// An ErrParamFormat represents a invalid format parameter error. -type ErrParamFormat struct { - errInvalidParam - format string -} - -// NewErrParamFormat creates a new invalid format parameter error. -func NewErrParamFormat(field string, format, value string) *ErrParamFormat { - return &ErrParamFormat{ - errInvalidParam: errInvalidParam{ - code: ParamFormatErrCode, - field: field, - msg: fmt.Sprintf("format %v, %v", format, value), - }, - format: format, - } -} - -// Format returns the field's required format. -func (e *ErrParamFormat) Format() string { - return e.format -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go deleted file mode 100644 index ea9ebb6f6..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport.go +++ /dev/null @@ -1,26 +0,0 @@ -// +build go1.7 - -package session - -import ( - "net" - "net/http" - "time" -) - -// Transport that should be used when a custom CA bundle is specified with the -// SDK. -func getCABundleTransport() *http.Transport { - return &http.Transport{ - Proxy: http.ProxyFromEnvironment, - DialContext: (&net.Dialer{ - Timeout: 30 * time.Second, - KeepAlive: 30 * time.Second, - DualStack: true, - }).DialContext, - MaxIdleConns: 100, - IdleConnTimeout: 90 * time.Second, - TLSHandshakeTimeout: 10 * time.Second, - ExpectContinueTimeout: 1 * time.Second, - } -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go deleted file mode 100644 index fec39dfc1..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_5.go +++ /dev/null @@ -1,22 +0,0 @@ -// +build !go1.6,go1.5 - -package session - -import ( - "net" - "net/http" - "time" -) - -// Transport that should be used when a custom CA bundle is specified with the -// SDK. -func getCABundleTransport() *http.Transport { - return &http.Transport{ - Proxy: http.ProxyFromEnvironment, - Dial: (&net.Dialer{ - Timeout: 30 * time.Second, - KeepAlive: 30 * time.Second, - }).Dial, - TLSHandshakeTimeout: 10 * time.Second, - } -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go b/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go deleted file mode 100644 index 1c5a5391e..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/cabundle_transport_1_6.go +++ /dev/null @@ -1,23 +0,0 @@ -// +build !go1.7,go1.6 - -package session - -import ( - "net" - "net/http" - "time" -) - -// Transport that should be used when a custom CA bundle is specified with the -// SDK. -func getCABundleTransport() *http.Transport { - return &http.Transport{ - Proxy: http.ProxyFromEnvironment, - Dial: (&net.Dialer{ - Timeout: 30 * time.Second, - KeepAlive: 30 * time.Second, - }).Dial, - TLSHandshakeTimeout: 10 * time.Second, - ExpectContinueTimeout: 1 * time.Second, - } -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go b/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go deleted file mode 100644 index 9c6fbfa77..000000000 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/credentials.go +++ /dev/null @@ -1,260 +0,0 @@ -package session - -import ( - "fmt" - "os" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/aws/credentials/processcreds" - "github.com/aws/aws-sdk-go/aws/credentials/stscreds" - "github.com/aws/aws-sdk-go/aws/defaults" - "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/internal/shareddefaults" -) - -func resolveCredentials(cfg *aws.Config, - envCfg envConfig, sharedCfg sharedConfig, - handlers request.Handlers, - sessOpts Options, -) (*credentials.Credentials, error) { - - switch { - case len(envCfg.Profile) != 0: - // User explicitly provided an Profile, so load from shared config - // first. - return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts) - - case envCfg.Creds.HasKeys(): - // Environment credentials - return credentials.NewStaticCredentialsFromCreds(envCfg.Creds), nil - - case len(envCfg.WebIdentityTokenFilePath) != 0: - // Web identity token from environment, RoleARN required to also be - // set. - return assumeWebIdentity(cfg, handlers, - envCfg.WebIdentityTokenFilePath, - envCfg.RoleARN, - envCfg.RoleSessionName, - ) - - default: - // Fallback to the "default" credential resolution chain. - return resolveCredsFromProfile(cfg, envCfg, sharedCfg, handlers, sessOpts) - } -} - -// WebIdentityEmptyRoleARNErr will occur if 'AWS_WEB_IDENTITY_TOKEN_FILE' was set but -// 'AWS_IAM_ROLE_ARN' was not set. -var WebIdentityEmptyRoleARNErr = awserr.New(stscreds.ErrCodeWebIdentity, "role ARN is not set", nil) - -// WebIdentityEmptyTokenFilePathErr will occur if 'AWS_IAM_ROLE_ARN' was set but -// 'AWS_WEB_IDENTITY_TOKEN_FILE' was not set. -var WebIdentityEmptyTokenFilePathErr = awserr.New(stscreds.ErrCodeWebIdentity, "token file path is not set", nil) - -func assumeWebIdentity(cfg *aws.Config, handlers request.Handlers, - filepath string, - roleARN, sessionName string, -) (*credentials.Credentials, error) { - - if len(filepath) == 0 { - return nil, WebIdentityEmptyTokenFilePathErr - } - - if len(roleARN) == 0 { - return nil, WebIdentityEmptyRoleARNErr - } - - creds := stscreds.NewWebIdentityCredentials( - &Session{ - Config: cfg, - Handlers: handlers.Copy(), - }, - roleARN, - sessionName, - filepath, - ) - - return creds, nil -} - -func resolveCredsFromProfile(cfg *aws.Config, - envCfg envConfig, sharedCfg sharedConfig, - handlers request.Handlers, - sessOpts Options, -) (creds *credentials.Credentials, err error) { - - switch { - case sharedCfg.SourceProfile != nil: - // Assume IAM role with credentials source from a different profile. - creds, err = resolveCredsFromProfile(cfg, envCfg, - *sharedCfg.SourceProfile, handlers, sessOpts, - ) - - case sharedCfg.Creds.HasKeys(): - // Static Credentials from Shared Config/Credentials file. - creds = credentials.NewStaticCredentialsFromCreds( - sharedCfg.Creds, - ) - - case len(sharedCfg.CredentialProcess) != 0: - // Get credentials from CredentialProcess - creds = processcreds.NewCredentials(sharedCfg.CredentialProcess) - - case len(sharedCfg.CredentialSource) != 0: - creds, err = resolveCredsFromSource(cfg, envCfg, - sharedCfg, handlers, sessOpts, - ) - - case len(sharedCfg.WebIdentityTokenFile) != 0: - // Credentials from Assume Web Identity token require an IAM Role, and - // that roll will be assumed. May be wrapped with another assume role - // via SourceProfile. - return assumeWebIdentity(cfg, handlers, - sharedCfg.WebIdentityTokenFile, - sharedCfg.RoleARN, - sharedCfg.RoleSessionName, - ) - - default: - // Fallback to default credentials provider, include mock errors for - // the credential chain so user can identify why credentials failed to - // be retrieved. - creds = credentials.NewCredentials(&credentials.ChainProvider{ - VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors), - Providers: []credentials.Provider{ - &credProviderError{ - Err: awserr.New("EnvAccessKeyNotFound", - "failed to find credentials in the environment.", nil), - }, - &credProviderError{ - Err: awserr.New("SharedCredsLoad", - fmt.Sprintf("failed to load profile, %s.", envCfg.Profile), nil), - }, - defaults.RemoteCredProvider(*cfg, handlers), - }, - }) - } - if err != nil { - return nil, err - } - - if len(sharedCfg.RoleARN) > 0 { - cfgCp := *cfg - cfgCp.Credentials = creds - return credsFromAssumeRole(cfgCp, handlers, sharedCfg, sessOpts) - } - - return creds, nil -} - -// valid credential source values -const ( - credSourceEc2Metadata = "Ec2InstanceMetadata" - credSourceEnvironment = "Environment" - credSourceECSContainer = "EcsContainer" -) - -func resolveCredsFromSource(cfg *aws.Config, - envCfg envConfig, sharedCfg sharedConfig, - handlers request.Handlers, - sessOpts Options, -) (creds *credentials.Credentials, err error) { - - switch sharedCfg.CredentialSource { - case credSourceEc2Metadata: - p := defaults.RemoteCredProvider(*cfg, handlers) - creds = credentials.NewCredentials(p) - - case credSourceEnvironment: - creds = credentials.NewStaticCredentialsFromCreds(envCfg.Creds) - - case credSourceECSContainer: - if len(os.Getenv(shareddefaults.ECSCredsProviderEnvVar)) == 0 { - return nil, ErrSharedConfigECSContainerEnvVarEmpty - } - - p := defaults.RemoteCredProvider(*cfg, handlers) - creds = credentials.NewCredentials(p) - - default: - return nil, ErrSharedConfigInvalidCredSource - } - - return creds, nil -} - -func credsFromAssumeRole(cfg aws.Config, - handlers request.Handlers, - sharedCfg sharedConfig, - sessOpts Options, -) (*credentials.Credentials, error) { - - if len(sharedCfg.MFASerial) != 0 && sessOpts.AssumeRoleTokenProvider == nil { - // AssumeRole Token provider is required if doing Assume Role - // with MFA. - return nil, AssumeRoleTokenProviderNotSetError{} - } - - return stscreds.NewCredentials( - &Session{ - Config: &cfg, - Handlers: handlers.Copy(), - }, - sharedCfg.RoleARN, - func(opt *stscreds.AssumeRoleProvider) { - opt.RoleSessionName = sharedCfg.RoleSessionName - opt.Duration = sessOpts.AssumeRoleDuration - - // Assume role with external ID - if len(sharedCfg.ExternalID) > 0 { - opt.ExternalID = aws.String(sharedCfg.ExternalID) - } - - // Assume role with MFA - if len(sharedCfg.MFASerial) > 0 { - opt.SerialNumber = aws.String(sharedCfg.MFASerial) - opt.TokenProvider = sessOpts.AssumeRoleTokenProvider - } - }, - ), nil -} - -// AssumeRoleTokenProviderNotSetError is an error returned when creating a -// session when the MFAToken option is not set when shared config is configured -// load assume a role with an MFA token. -type AssumeRoleTokenProviderNotSetError struct{} - -// Code is the short id of the error. -func (e AssumeRoleTokenProviderNotSetError) Code() string { - return "AssumeRoleTokenProviderNotSetError" -} - -// Message is the description of the error -func (e AssumeRoleTokenProviderNotSetError) Message() string { - return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.") -} - -// OrigErr is the underlying error that caused the failure. -func (e AssumeRoleTokenProviderNotSetError) OrigErr() error { - return nil -} - -// Error satisfies the error interface. -func (e AssumeRoleTokenProviderNotSetError) Error() string { - return awserr.SprintError(e.Code(), e.Message(), "", nil) -} - -type credProviderError struct { - Err error -} - -var emptyCreds = credentials.Value{} - -func (c credProviderError) Retrieve() (credentials.Value, error) { - return credentials.Value{}, c.Err -} -func (c credProviderError) IsExpired() bool { - return true -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go index 38a7b05a6..98d420fd6 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go @@ -99,7 +99,7 @@ handler logs every request and its payload made by a service client: sess.Handlers.Send.PushFront(func(r *request.Request) { // Log every request made and its payload - logger.Printf("Request: %s/%s, Payload: %s", + logger.Println("Request: %s/%s, Payload: %s", r.ClientInfo.ServiceName, r.Operation, r.Params) }) @@ -183,7 +183,7 @@ be returned when creating the session. // from assumed role. svc := s3.New(sess) -To setup assume role outside of a session see the stscreds.AssumeRoleProvider +To setup assume role outside of a session see the stscrds.AssumeRoleProvider documentation. Environment Variables diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go index 3a998d5bd..82e04d76c 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go @@ -4,7 +4,6 @@ import ( "os" "strconv" - "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/defaults" ) @@ -80,7 +79,7 @@ type envConfig struct { // AWS_CONFIG_FILE=$HOME/my_shared_config SharedConfigFile string - // Sets the path to a custom Credentials Authority (CA) Bundle PEM file + // Sets the path to a custom Credentials Authroity (CA) Bundle PEM file // that the SDK will use instead of the system's root CA bundle. // Only use this if you want to configure the SDK to use a custom set // of CAs. @@ -102,38 +101,12 @@ type envConfig struct { CSMEnabled bool CSMPort string CSMClientID string - CSMHost string - - // Enables endpoint discovery via environment variables. - // - // AWS_ENABLE_ENDPOINT_DISCOVERY=true - EnableEndpointDiscovery *bool - enableEndpointDiscovery string - - // Specifies the WebIdentity token the SDK should use to assume a role - // with. - // - // AWS_WEB_IDENTITY_TOKEN_FILE=file_path - WebIdentityTokenFilePath string - - // Specifies the IAM role arn to use when assuming an role. - // - // AWS_ROLE_ARN=role_arn - RoleARN string - - // Specifies the IAM role session name to use when assuming a role. - // - // AWS_ROLE_SESSION_NAME=session_name - RoleSessionName string } var ( csmEnabledEnvKey = []string{ "AWS_CSM_ENABLED", } - csmHostEnvKey = []string{ - "AWS_CSM_HOST", - } csmPortEnvKey = []string{ "AWS_CSM_PORT", } @@ -152,10 +125,6 @@ var ( "AWS_SESSION_TOKEN", } - enableEndpointDiscoveryEnvKey = []string{ - "AWS_ENABLE_ENDPOINT_DISCOVERY", - } - regionEnvKeys = []string{ "AWS_REGION", "AWS_DEFAULT_REGION", // Only read if AWS_SDK_LOAD_CONFIG is also set @@ -170,15 +139,6 @@ var ( sharedConfigFileEnvKey = []string{ "AWS_CONFIG_FILE", } - webIdentityTokenFilePathEnvKey = []string{ - "AWS_WEB_IDENTITY_TOKEN_FILE", - } - roleARNEnvKey = []string{ - "AWS_ROLE_ARN", - } - roleSessionNameEnvKey = []string{ - "AWS_ROLE_SESSION_NAME", - } ) // loadEnvConfig retrieves the SDK's environment configuration. @@ -207,31 +167,23 @@ func envConfigLoad(enableSharedConfig bool) envConfig { cfg.EnableSharedConfig = enableSharedConfig - // Static environment credentials - var creds credentials.Value - setFromEnvVal(&creds.AccessKeyID, credAccessEnvKey) - setFromEnvVal(&creds.SecretAccessKey, credSecretEnvKey) - setFromEnvVal(&creds.SessionToken, credSessionEnvKey) - if creds.HasKeys() { - // Require logical grouping of credentials - creds.ProviderName = EnvProviderName - cfg.Creds = creds - } - - // Role Metadata - setFromEnvVal(&cfg.RoleARN, roleARNEnvKey) - setFromEnvVal(&cfg.RoleSessionName, roleSessionNameEnvKey) - - // Web identity environment variables - setFromEnvVal(&cfg.WebIdentityTokenFilePath, webIdentityTokenFilePathEnvKey) + setFromEnvVal(&cfg.Creds.AccessKeyID, credAccessEnvKey) + setFromEnvVal(&cfg.Creds.SecretAccessKey, credSecretEnvKey) + setFromEnvVal(&cfg.Creds.SessionToken, credSessionEnvKey) // CSM environment variables setFromEnvVal(&cfg.csmEnabled, csmEnabledEnvKey) - setFromEnvVal(&cfg.CSMHost, csmHostEnvKey) setFromEnvVal(&cfg.CSMPort, csmPortEnvKey) setFromEnvVal(&cfg.CSMClientID, csmClientIDEnvKey) cfg.CSMEnabled = len(cfg.csmEnabled) > 0 + // Require logical grouping of credentials + if len(cfg.Creds.AccessKeyID) == 0 || len(cfg.Creds.SecretAccessKey) == 0 { + cfg.Creds = credentials.Value{} + } else { + cfg.Creds.ProviderName = EnvProviderName + } + regionKeys := regionEnvKeys profileKeys := profileEnvKeys if !cfg.EnableSharedConfig { @@ -242,12 +194,6 @@ func envConfigLoad(enableSharedConfig bool) envConfig { setFromEnvVal(&cfg.Region, regionKeys) setFromEnvVal(&cfg.Profile, profileKeys) - // endpoint discovery is in reference to it being enabled. - setFromEnvVal(&cfg.enableEndpointDiscovery, enableEndpointDiscoveryEnvKey) - if len(cfg.enableEndpointDiscovery) > 0 { - cfg.EnableEndpointDiscovery = aws.Bool(cfg.enableEndpointDiscovery != "false") - } - setFromEnvVal(&cfg.SharedCredentialsFile, sharedCredsFileEnvKey) setFromEnvVal(&cfg.SharedConfigFile, sharedConfigFileEnvKey) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go index 3a28da5a8..51f305563 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go @@ -8,36 +8,19 @@ import ( "io/ioutil" "net/http" "os" - "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/corehandlers" "github.com/aws/aws-sdk-go/aws/credentials" + "github.com/aws/aws-sdk-go/aws/credentials/stscreds" "github.com/aws/aws-sdk-go/aws/csm" "github.com/aws/aws-sdk-go/aws/defaults" "github.com/aws/aws-sdk-go/aws/endpoints" "github.com/aws/aws-sdk-go/aws/request" ) -const ( - // ErrCodeSharedConfig represents an error that occurs in the shared - // configuration logic - ErrCodeSharedConfig = "SharedConfigErr" -) - -// ErrSharedConfigSourceCollision will be returned if a section contains both -// source_profile and credential_source -var ErrSharedConfigSourceCollision = awserr.New(ErrCodeSharedConfig, "only source profile or credential source can be specified, not both", nil) - -// ErrSharedConfigECSContainerEnvVarEmpty will be returned if the environment -// variables are empty and Environment was set as the credential source -var ErrSharedConfigECSContainerEnvVarEmpty = awserr.New(ErrCodeSharedConfig, "EcsContainer was specified as the credential_source, but 'AWS_CONTAINER_CREDENTIALS_RELATIVE_URI' was not set", nil) - -// ErrSharedConfigInvalidCredSource will be returned if an invalid credential source was provided -var ErrSharedConfigInvalidCredSource = awserr.New(ErrCodeSharedConfig, "credential source values must be EcsContainer, Ec2InstanceMetadata, or Environment", nil) - // A Session provides a central location to create service clients from and // store configurations and request handlers for those services. // @@ -105,15 +88,7 @@ func New(cfgs ...*aws.Config) *Session { s := deprecatedNewSession(cfgs...) if envCfg.CSMEnabled { - err := enableCSM(&s.Handlers, envCfg.CSMClientID, - envCfg.CSMHost, envCfg.CSMPort, s.Config.Logger) - if err != nil { - err = fmt.Errorf("failed to enable CSM, %v", err) - s.Config.Logger.Log("ERROR:", err.Error()) - s.Handlers.Validate.PushBack(func(r *request.Request) { - r.Error = err - }) - } + enableCSM(&s.Handlers, envCfg.CSMClientID, envCfg.CSMPort, s.Config.Logger) } return s @@ -216,12 +191,6 @@ type Options struct { // the config enables assume role wit MFA via the mfa_serial field. AssumeRoleTokenProvider func() (string, error) - // When the SDK's shared config is configured to assume a role this option - // may be provided to set the expiry duration of the STS credentials. - // Defaults to 15 minutes if not set as documented in the - // stscreds.AssumeRoleProvider. - AssumeRoleDuration time.Duration - // Reader for a custom Credentials Authority (CA) bundle in PEM format that // the SDK will use instead of the default system's root CA bundle. Use this // only if you want to replace the CA bundle the SDK uses for TLS requests. @@ -236,12 +205,6 @@ type Options struct { // to also enable this feature. CustomCABundle session option field has priority // over the AWS_CA_BUNDLE environment variable, and will be used if both are set. CustomCABundle io.Reader - - // The handlers that the session and all API clients will be created with. - // This must be a complete set of handlers. Use the defaults.Handlers() - // function to initialize this value before changing the handlers to be - // used by the SDK. - Handlers request.Handlers } // NewSessionWithOptions returns a new Session created from SDK defaults, config files, @@ -347,36 +310,27 @@ func deprecatedNewSession(cfgs ...*aws.Config) *Session { return s } -func enableCSM(handlers *request.Handlers, - clientID, host, port string, - logger aws.Logger, -) error { - if logger != nil { - logger.Log("Enabling CSM") +func enableCSM(handlers *request.Handlers, clientID string, port string, logger aws.Logger) { + logger.Log("Enabling CSM") + if len(port) == 0 { + port = csm.DefaultPort } - r, err := csm.Start(clientID, csm.AddressWithDefaults(host, port)) + r, err := csm.Start(clientID, "127.0.0.1:"+port) if err != nil { - return err + return } r.InjectHandlers(handlers) - - return nil } func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, error) { cfg := defaults.Config() - - handlers := opts.Handlers - if handlers.IsEmpty() { - handlers = defaults.Handlers() - } + handlers := defaults.Handlers() // Get a merged version of the user provided config to determine if // credentials were. userCfg := &aws.Config{} userCfg.MergeIn(cfgs...) - cfg.MergeIn(userCfg) // Ordered config files will be loaded in with later files overwriting // previous config file values. @@ -393,11 +347,9 @@ func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, } // Load additional config from file(s) - sharedCfg, err := loadSharedConfig(envCfg.Profile, cfgFiles, envCfg.EnableSharedConfig) + sharedCfg, err := loadSharedConfig(envCfg.Profile, cfgFiles) if err != nil { - if _, ok := err.(SharedConfigProfileNotExistsError); !ok { - return nil, err - } + return nil, err } if err := mergeConfigSrcs(cfg, userCfg, envCfg, sharedCfg, handlers, opts); err != nil { @@ -411,11 +363,7 @@ func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, initHandlers(s) if envCfg.CSMEnabled { - err := enableCSM(&s.Handlers, envCfg.CSMClientID, - envCfg.CSMHost, envCfg.CSMPort, s.Config.Logger) - if err != nil { - return nil, err - } + enableCSM(&s.Handlers, envCfg.CSMClientID, envCfg.CSMPort, s.Config.Logger) } // Setup HTTP client with custom cert bundle if enabled @@ -440,10 +388,7 @@ func loadCustomCABundle(s *Session, bundle io.Reader) error { } } if t == nil { - // Nil transport implies `http.DefaultTransport` should be used. Since - // the SDK cannot modify, nor copy the `DefaultTransport` specifying - // the values the next closest behavior. - t = getCABundleTransport() + t = &http.Transport{} } p, err := loadCertPool(bundle) @@ -476,11 +421,9 @@ func loadCertPool(r io.Reader) (*x509.CertPool, error) { return p, nil } -func mergeConfigSrcs(cfg, userCfg *aws.Config, - envCfg envConfig, sharedCfg sharedConfig, - handlers request.Handlers, - sessOpts Options, -) error { +func mergeConfigSrcs(cfg, userCfg *aws.Config, envCfg envConfig, sharedCfg sharedConfig, handlers request.Handlers, sessOpts Options) error { + // Merge in user provided configuration + cfg.MergeIn(userCfg) // Region if not already set by user if len(aws.StringValue(cfg.Region)) == 0 { @@ -491,27 +434,103 @@ func mergeConfigSrcs(cfg, userCfg *aws.Config, } } - if cfg.EnableEndpointDiscovery == nil { - if envCfg.EnableEndpointDiscovery != nil { - cfg.WithEndpointDiscovery(*envCfg.EnableEndpointDiscovery) - } else if envCfg.EnableSharedConfig && sharedCfg.EnableEndpointDiscovery != nil { - cfg.WithEndpointDiscovery(*sharedCfg.EnableEndpointDiscovery) - } - } - - // Configure credentials if not already set by the user when creating the - // Session. + // Configure credentials if not already set if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil { - creds, err := resolveCredentials(cfg, envCfg, sharedCfg, handlers, sessOpts) - if err != nil { - return err + if len(envCfg.Creds.AccessKeyID) > 0 { + cfg.Credentials = credentials.NewStaticCredentialsFromCreds( + envCfg.Creds, + ) + } else if envCfg.EnableSharedConfig && len(sharedCfg.AssumeRole.RoleARN) > 0 && sharedCfg.AssumeRoleSource != nil { + cfgCp := *cfg + cfgCp.Credentials = credentials.NewStaticCredentialsFromCreds( + sharedCfg.AssumeRoleSource.Creds, + ) + if len(sharedCfg.AssumeRole.MFASerial) > 0 && sessOpts.AssumeRoleTokenProvider == nil { + // AssumeRole Token provider is required if doing Assume Role + // with MFA. + return AssumeRoleTokenProviderNotSetError{} + } + cfg.Credentials = stscreds.NewCredentials( + &Session{ + Config: &cfgCp, + Handlers: handlers.Copy(), + }, + sharedCfg.AssumeRole.RoleARN, + func(opt *stscreds.AssumeRoleProvider) { + opt.RoleSessionName = sharedCfg.AssumeRole.RoleSessionName + + // Assume role with external ID + if len(sharedCfg.AssumeRole.ExternalID) > 0 { + opt.ExternalID = aws.String(sharedCfg.AssumeRole.ExternalID) + } + + // Assume role with MFA + if len(sharedCfg.AssumeRole.MFASerial) > 0 { + opt.SerialNumber = aws.String(sharedCfg.AssumeRole.MFASerial) + opt.TokenProvider = sessOpts.AssumeRoleTokenProvider + } + }, + ) + } else if len(sharedCfg.Creds.AccessKeyID) > 0 { + cfg.Credentials = credentials.NewStaticCredentialsFromCreds( + sharedCfg.Creds, + ) + } else { + // Fallback to default credentials provider, include mock errors + // for the credential chain so user can identify why credentials + // failed to be retrieved. + cfg.Credentials = credentials.NewCredentials(&credentials.ChainProvider{ + VerboseErrors: aws.BoolValue(cfg.CredentialsChainVerboseErrors), + Providers: []credentials.Provider{ + &credProviderError{Err: awserr.New("EnvAccessKeyNotFound", "failed to find credentials in the environment.", nil)}, + &credProviderError{Err: awserr.New("SharedCredsLoad", fmt.Sprintf("failed to load profile, %s.", envCfg.Profile), nil)}, + defaults.RemoteCredProvider(*cfg, handlers), + }, + }) } - cfg.Credentials = creds } return nil } +// AssumeRoleTokenProviderNotSetError is an error returned when creating a session when the +// MFAToken option is not set when shared config is configured load assume a +// role with an MFA token. +type AssumeRoleTokenProviderNotSetError struct{} + +// Code is the short id of the error. +func (e AssumeRoleTokenProviderNotSetError) Code() string { + return "AssumeRoleTokenProviderNotSetError" +} + +// Message is the description of the error +func (e AssumeRoleTokenProviderNotSetError) Message() string { + return fmt.Sprintf("assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.") +} + +// OrigErr is the underlying error that caused the failure. +func (e AssumeRoleTokenProviderNotSetError) OrigErr() error { + return nil +} + +// Error satisfies the error interface. +func (e AssumeRoleTokenProviderNotSetError) Error() string { + return awserr.SprintError(e.Code(), e.Message(), "", nil) +} + +type credProviderError struct { + Err error +} + +var emptyCreds = credentials.Value{} + +func (c credProviderError) Retrieve() (credentials.Value, error) { + return credentials.Value{}, c.Err +} +func (c credProviderError) IsExpired() bool { + return true +} + func initHandlers(s *Session) { // Add the Validate parameter handler if it is not disabled. s.Handlers.Validate.Remove(corehandlers.ValidateParametersHandler) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go b/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go index 5170b4982..09c8e5bc7 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go @@ -2,10 +2,11 @@ package session import ( "fmt" + "io/ioutil" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/credentials" - "github.com/aws/aws-sdk-go/internal/ini" + "github.com/go-ini/ini" ) const ( @@ -15,86 +16,68 @@ const ( sessionTokenKey = `aws_session_token` // optional // Assume Role Credentials group - roleArnKey = `role_arn` // group required - sourceProfileKey = `source_profile` // group required (or credential_source) - credentialSourceKey = `credential_source` // group required (or source_profile) - externalIDKey = `external_id` // optional - mfaSerialKey = `mfa_serial` // optional - roleSessionNameKey = `role_session_name` // optional + roleArnKey = `role_arn` // group required + sourceProfileKey = `source_profile` // group required + externalIDKey = `external_id` // optional + mfaSerialKey = `mfa_serial` // optional + roleSessionNameKey = `role_session_name` // optional // Additional Config fields regionKey = `region` - // endpoint discovery group - enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional - - // External Credential Process - credentialProcessKey = `credential_process` // optional - - // Web Identity Token File - webIdentityTokenFileKey = `web_identity_token_file` // optional - // DefaultSharedConfigProfile is the default profile to be used when // loading configuration from the config files if another profile name // is not provided. DefaultSharedConfigProfile = `default` ) +type assumeRoleConfig struct { + RoleARN string + SourceProfile string + ExternalID string + MFASerial string + RoleSessionName string +} + // sharedConfig represents the configuration fields of the SDK config files. type sharedConfig struct { - // Credentials values from the config file. Both aws_access_key_id and - // aws_secret_access_key must be provided together in the same file to be - // considered valid. The values will be ignored if not a complete group. - // aws_session_token is an optional field that can be provided if both of - // the other two fields are also provided. + // Credentials values from the config file. Both aws_access_key_id + // and aws_secret_access_key must be provided together in the same file + // to be considered valid. The values will be ignored if not a complete group. + // aws_session_token is an optional field that can be provided if both of the + // other two fields are also provided. // // aws_access_key_id // aws_secret_access_key // aws_session_token Creds credentials.Value - CredentialSource string - CredentialProcess string - WebIdentityTokenFile string + AssumeRole assumeRoleConfig + AssumeRoleSource *sharedConfig - RoleARN string - RoleSessionName string - ExternalID string - MFASerial string - - SourceProfileName string - SourceProfile *sharedConfig - - // Region is the region the SDK should use for looking up AWS service - // endpoints and signing requests. + // Region is the region the SDK should use for looking up AWS service endpoints + // and signing requests. // // region Region string - - // EnableEndpointDiscovery can be enabled in the shared config by setting - // endpoint_discovery_enabled to true - // - // endpoint_discovery_enabled = true - EnableEndpointDiscovery *bool } type sharedConfigFile struct { Filename string - IniData ini.Sections + IniData *ini.File } -// loadSharedConfig retrieves the configuration from the list of files using -// the profile provided. The order the files are listed will determine +// loadSharedConfig retrieves the configuration from the list of files +// using the profile provided. The order the files are listed will determine // precedence. Values in subsequent files will overwrite values defined in // earlier files. // // For example, given two files A and B. Both define credentials. If the order -// of the files are A then B, B's credential values will be used instead of -// A's. +// of the files are A then B, B's credential values will be used instead of A's. // // See sharedConfig.setFromFile for information how the config files // will be loaded. -func loadSharedConfig(profile string, filenames []string, exOpts bool) (sharedConfig, error) { +func loadSharedConfig(profile string, filenames []string) (sharedConfig, error) { if len(profile) == 0 { profile = DefaultSharedConfigProfile } @@ -105,11 +88,16 @@ func loadSharedConfig(profile string, filenames []string, exOpts bool) (sharedCo } cfg := sharedConfig{} - profiles := map[string]struct{}{} - if err = cfg.setFromIniFiles(profiles, profile, files, exOpts); err != nil { + if err = cfg.setFromIniFiles(profile, files); err != nil { return sharedConfig{}, err } + if len(cfg.AssumeRole.SourceProfile) > 0 { + if err := cfg.setAssumeRoleSource(profile, files); err != nil { + return sharedConfig{}, err + } + } + return cfg, nil } @@ -117,235 +105,112 @@ func loadSharedConfigIniFiles(filenames []string) ([]sharedConfigFile, error) { files := make([]sharedConfigFile, 0, len(filenames)) for _, filename := range filenames { - sections, err := ini.OpenFile(filename) - if aerr, ok := err.(awserr.Error); ok && aerr.Code() == ini.ErrCodeUnableToReadFile { + b, err := ioutil.ReadFile(filename) + if err != nil { // Skip files which can't be opened and read for whatever reason continue - } else if err != nil { + } + + f, err := ini.Load(b) + if err != nil { return nil, SharedConfigLoadError{Filename: filename, Err: err} } files = append(files, sharedConfigFile{ - Filename: filename, IniData: sections, + Filename: filename, IniData: f, }) } return files, nil } -func (cfg *sharedConfig) setFromIniFiles(profiles map[string]struct{}, profile string, files []sharedConfigFile, exOpts bool) error { +func (cfg *sharedConfig) setAssumeRoleSource(origProfile string, files []sharedConfigFile) error { + var assumeRoleSrc sharedConfig + + // Multiple level assume role chains are not support + if cfg.AssumeRole.SourceProfile == origProfile { + assumeRoleSrc = *cfg + assumeRoleSrc.AssumeRole = assumeRoleConfig{} + } else { + err := assumeRoleSrc.setFromIniFiles(cfg.AssumeRole.SourceProfile, files) + if err != nil { + return err + } + } + + if len(assumeRoleSrc.Creds.AccessKeyID) == 0 { + return SharedConfigAssumeRoleError{RoleARN: cfg.AssumeRole.RoleARN} + } + + cfg.AssumeRoleSource = &assumeRoleSrc + + return nil +} + +func (cfg *sharedConfig) setFromIniFiles(profile string, files []sharedConfigFile) error { // Trim files from the list that don't exist. - var skippedFiles int - var profileNotFoundErr error for _, f := range files { - if err := cfg.setFromIniFile(profile, f, exOpts); err != nil { + if err := cfg.setFromIniFile(profile, f); err != nil { if _, ok := err.(SharedConfigProfileNotExistsError); ok { - // Ignore profiles not defined in individual files. - profileNotFoundErr = err - skippedFiles++ + // Ignore proviles missings continue } return err } } - if skippedFiles == len(files) { - // If all files were skipped because the profile is not found, return - // the original profile not found error. - return profileNotFoundErr - } - - if _, ok := profiles[profile]; ok { - // if this is the second instance of the profile the Assume Role - // options must be cleared because they are only valid for the - // first reference of a profile. The self linked instance of the - // profile only have credential provider options. - cfg.clearAssumeRoleOptions() - } else { - // First time a profile has been seen, It must either be a assume role - // or credentials. Assert if the credential type requires a role ARN, - // the ARN is also set. - if err := cfg.validateCredentialsRequireARN(profile); err != nil { - return err - } - } - profiles[profile] = struct{}{} - - if err := cfg.validateCredentialType(); err != nil { - return err - } - - // Link source profiles for assume roles - if len(cfg.SourceProfileName) != 0 { - // Linked profile via source_profile ignore credential provider - // options, the source profile must provide the credentials. - cfg.clearCredentialOptions() - - srcCfg := &sharedConfig{} - err := srcCfg.setFromIniFiles(profiles, cfg.SourceProfileName, files, exOpts) - if err != nil { - // SourceProfile that doesn't exist is an error in configuration. - if _, ok := err.(SharedConfigProfileNotExistsError); ok { - err = SharedConfigAssumeRoleError{ - RoleARN: cfg.RoleARN, - SourceProfile: cfg.SourceProfileName, - } - } - return err - } - - if !srcCfg.hasCredentials() { - return SharedConfigAssumeRoleError{ - RoleARN: cfg.RoleARN, - SourceProfile: cfg.SourceProfileName, - } - } - - cfg.SourceProfile = srcCfg - } return nil } -// setFromFile loads the configuration from the file using the profile -// provided. A sharedConfig pointer type value is used so that multiple config -// file loadings can be chained. +// setFromFile loads the configuration from the file using +// the profile provided. A sharedConfig pointer type value is used so that +// multiple config file loadings can be chained. // // Only loads complete logically grouped values, and will not set fields in cfg -// for incomplete grouped values in the config. Such as credentials. For -// example if a config file only includes aws_access_key_id but no -// aws_secret_access_key the aws_access_key_id will be ignored. -func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile, exOpts bool) error { - section, ok := file.IniData.GetSection(profile) - if !ok { +// for incomplete grouped values in the config. Such as credentials. For example +// if a config file only includes aws_access_key_id but no aws_secret_access_key +// the aws_access_key_id will be ignored. +func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile) error { + section, err := file.IniData.GetSection(profile) + if err != nil { // Fallback to to alternate profile name: profile - section, ok = file.IniData.GetSection(fmt.Sprintf("profile %s", profile)) - if !ok { - return SharedConfigProfileNotExistsError{Profile: profile, Err: nil} + section, err = file.IniData.GetSection(fmt.Sprintf("profile %s", profile)) + if err != nil { + return SharedConfigProfileNotExistsError{Profile: profile, Err: err} } } - if exOpts { - // Assume Role Parameters - updateString(&cfg.RoleARN, section, roleArnKey) - updateString(&cfg.ExternalID, section, externalIDKey) - updateString(&cfg.MFASerial, section, mfaSerialKey) - updateString(&cfg.RoleSessionName, section, roleSessionNameKey) - updateString(&cfg.SourceProfileName, section, sourceProfileKey) - updateString(&cfg.CredentialSource, section, credentialSourceKey) - - updateString(&cfg.Region, section, regionKey) - } - - updateString(&cfg.CredentialProcess, section, credentialProcessKey) - updateString(&cfg.WebIdentityTokenFile, section, webIdentityTokenFileKey) - // Shared Credentials - creds := credentials.Value{ - AccessKeyID: section.String(accessKeyIDKey), - SecretAccessKey: section.String(secretAccessKey), - SessionToken: section.String(sessionTokenKey), - ProviderName: fmt.Sprintf("SharedConfigCredentials: %s", file.Filename), - } - if creds.HasKeys() { - cfg.Creds = creds - } - - // Endpoint discovery - if section.Has(enableEndpointDiscoveryKey) { - v := section.Bool(enableEndpointDiscoveryKey) - cfg.EnableEndpointDiscovery = &v - } - - return nil -} - -func (cfg *sharedConfig) validateCredentialsRequireARN(profile string) error { - var credSource string - - switch { - case len(cfg.SourceProfileName) != 0: - credSource = sourceProfileKey - case len(cfg.CredentialSource) != 0: - credSource = credentialSourceKey - case len(cfg.WebIdentityTokenFile) != 0: - credSource = webIdentityTokenFileKey - } - - if len(credSource) != 0 && len(cfg.RoleARN) == 0 { - return CredentialRequiresARNError{ - Type: credSource, - Profile: profile, + akid := section.Key(accessKeyIDKey).String() + secret := section.Key(secretAccessKey).String() + if len(akid) > 0 && len(secret) > 0 { + cfg.Creds = credentials.Value{ + AccessKeyID: akid, + SecretAccessKey: secret, + SessionToken: section.Key(sessionTokenKey).String(), + ProviderName: fmt.Sprintf("SharedConfigCredentials: %s", file.Filename), } } - return nil -} - -func (cfg *sharedConfig) validateCredentialType() error { - // Only one or no credential type can be defined. - if !oneOrNone( - len(cfg.SourceProfileName) != 0, - len(cfg.CredentialSource) != 0, - len(cfg.CredentialProcess) != 0, - len(cfg.WebIdentityTokenFile) != 0, - ) { - return ErrSharedConfigSourceCollision - } - - return nil -} - -func (cfg *sharedConfig) hasCredentials() bool { - switch { - case len(cfg.SourceProfileName) != 0: - case len(cfg.CredentialSource) != 0: - case len(cfg.CredentialProcess) != 0: - case len(cfg.WebIdentityTokenFile) != 0: - case cfg.Creds.HasKeys(): - default: - return false - } - - return true -} - -func (cfg *sharedConfig) clearCredentialOptions() { - cfg.CredentialSource = "" - cfg.CredentialProcess = "" - cfg.WebIdentityTokenFile = "" - cfg.Creds = credentials.Value{} -} - -func (cfg *sharedConfig) clearAssumeRoleOptions() { - cfg.RoleARN = "" - cfg.ExternalID = "" - cfg.MFASerial = "" - cfg.RoleSessionName = "" - cfg.SourceProfileName = "" -} - -func oneOrNone(bs ...bool) bool { - var count int - - for _, b := range bs { - if b { - count++ - if count > 1 { - return false - } + // Assume Role + roleArn := section.Key(roleArnKey).String() + srcProfile := section.Key(sourceProfileKey).String() + if len(roleArn) > 0 && len(srcProfile) > 0 { + cfg.AssumeRole = assumeRoleConfig{ + RoleARN: roleArn, + SourceProfile: srcProfile, + ExternalID: section.Key(externalIDKey).String(), + MFASerial: section.Key(mfaSerialKey).String(), + RoleSessionName: section.Key(roleSessionNameKey).String(), } } - return true -} - -// updateString will only update the dst with the value in the section key, key -// is present in the section. -func updateString(dst *string, section ini.Section, key string) { - if !section.Has(key) { - return + // Region + if v := section.Key(regionKey).String(); len(v) > 0 { + cfg.Region = v } - *dst = section.String(key) + + return nil } // SharedConfigLoadError is an error for the shared config file failed to load. @@ -405,8 +270,7 @@ func (e SharedConfigProfileNotExistsError) Error() string { // profile contains assume role information, but that information is invalid // or not complete. type SharedConfigAssumeRoleError struct { - RoleARN string - SourceProfile string + RoleARN string } // Code is the short id of the error. @@ -416,10 +280,8 @@ func (e SharedConfigAssumeRoleError) Code() string { // Message is the description of the error func (e SharedConfigAssumeRoleError) Message() string { - return fmt.Sprintf( - "failed to load assume role for %s, source profile %s has no shared credentials", - e.RoleARN, e.SourceProfile, - ) + return fmt.Sprintf("failed to load assume role for %s, source profile has no shared credentials", + e.RoleARN) } // OrigErr is the underlying error that caused the failure. @@ -431,36 +293,3 @@ func (e SharedConfigAssumeRoleError) OrigErr() error { func (e SharedConfigAssumeRoleError) Error() string { return awserr.SprintError(e.Code(), e.Message(), "", nil) } - -// CredentialRequiresARNError provides the error for shared config credentials -// that are incorrectly configured in the shared config or credentials file. -type CredentialRequiresARNError struct { - // type of credentials that were configured. - Type string - - // Profile name the credentials were in. - Profile string -} - -// Code is the short id of the error. -func (e CredentialRequiresARNError) Code() string { - return "CredentialRequiresARNError" -} - -// Message is the description of the error -func (e CredentialRequiresARNError) Message() string { - return fmt.Sprintf( - "credential type %s requires role_arn, profile %s", - e.Type, e.Profile, - ) -} - -// OrigErr is the underlying error that caused the failure. -func (e CredentialRequiresARNError) OrigErr() error { - return nil -} - -// Error satisfies the error interface. -func (e CredentialRequiresARNError) Error() string { - return awserr.SprintError(e.Code(), e.Message(), "", nil) -} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go index 523db79f8..8aa0681d3 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go @@ -134,7 +134,6 @@ var requiredSignedHeaders = rules{ "X-Amz-Server-Side-Encryption-Customer-Key": struct{}{}, "X-Amz-Server-Side-Encryption-Customer-Key-Md5": struct{}{}, "X-Amz-Storage-Class": struct{}{}, - "X-Amz-Tagging": struct{}{}, "X-Amz-Website-Redirect-Location": struct{}{}, "X-Amz-Content-Sha256": struct{}{}, }, @@ -182,7 +181,7 @@ type Signer struct { // http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html DisableURIPathEscaping bool - // Disables the automatical setting of the HTTP request's Body field with the + // Disales the automatical setting of the HTTP request's Body field with the // io.ReadSeeker passed in to the signer. This is useful if you're using a // custom wrapper around the body for the io.ReadSeeker and want to preserve // the Body value on the Request.Body. @@ -422,7 +421,7 @@ var SignRequestHandler = request.NamedHandler{ // If the credentials of the request's config are set to // credentials.AnonymousCredentials the request will not be signed. func SignSDKRequest(req *request.Request) { - SignSDKRequestWithCurrentTime(req, time.Now) + signSDKRequestWithCurrTime(req, time.Now) } // BuildNamedHandler will build a generic handler for signing. @@ -430,15 +429,12 @@ func BuildNamedHandler(name string, opts ...func(*Signer)) request.NamedHandler return request.NamedHandler{ Name: name, Fn: func(req *request.Request) { - SignSDKRequestWithCurrentTime(req, time.Now, opts...) + signSDKRequestWithCurrTime(req, time.Now, opts...) }, } } -// SignSDKRequestWithCurrentTime will sign the SDK's request using the time -// function passed in. Behaves the same as SignSDKRequest with the exception -// the request is signed with the value returned by the current time function. -func SignSDKRequestWithCurrentTime(req *request.Request, curTimeFn func() time.Time, opts ...func(*Signer)) { +func signSDKRequestWithCurrTime(req *request.Request, curTimeFn func() time.Time, opts ...func(*Signer)) { // If the request does not need to be signed ignore the signing of the // request if the AnonymousCredentials object is used. if req.Config.Credentials == credentials.AnonymousCredentials { @@ -474,9 +470,13 @@ func SignSDKRequestWithCurrentTime(req *request.Request, curTimeFn func() time.T opt(v4) } - curTime := curTimeFn() + signingTime := req.Time + if !req.LastSignedAt.IsZero() { + signingTime = req.LastSignedAt + } + signedHeaders, err := v4.signWithBody(req.HTTPRequest, req.GetBody(), - name, region, req.ExpireTime, req.ExpireTime > 0, curTime, + name, region, req.ExpireTime, req.ExpireTime > 0, signingTime, ) if err != nil { req.Error = err @@ -485,7 +485,7 @@ func SignSDKRequestWithCurrentTime(req *request.Request, curTimeFn func() time.T } req.SignedHeaderVals = signedHeaders - req.LastSignedAt = curTime + req.LastSignedAt = curTimeFn() } const logSignInfoMsg = `DEBUG: Request Signature: @@ -739,22 +739,14 @@ func makeSha256Reader(reader io.ReadSeeker) []byte { start, _ := reader.Seek(0, sdkio.SeekCurrent) defer reader.Seek(start, sdkio.SeekStart) - // Use CopyN to avoid allocating the 32KB buffer in io.Copy for bodies - // smaller than 32KB. Fall back to io.Copy if we fail to determine the size. - size, err := aws.SeekerLen(reader) - if err != nil { - io.Copy(hash, reader) - } else { - io.CopyN(hash, reader, size) - } - + io.Copy(hash, reader) return hash.Sum(nil) } const doubleSpace = " " // stripExcessSpaces will rewrite the passed in slice's string values to not -// contain multiple side-by-side spaces. +// contain muliple side-by-side spaces. func stripExcessSpaces(vals []string) { var j, k, l, m, spaces int for i, str := range vals { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/types.go b/vendor/github.com/aws/aws-sdk-go/aws/types.go index 455091540..8b6f23425 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/types.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/types.go @@ -7,18 +7,13 @@ import ( "github.com/aws/aws-sdk-go/internal/sdkio" ) -// ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Allows the -// SDK to accept an io.Reader that is not also an io.Seeker for unsigned -// streaming payload API operations. +// ReadSeekCloser wraps a io.Reader returning a ReaderSeekerCloser. Should +// only be used with an io.Reader that is also an io.Seeker. Doing so may +// cause request signature errors, or request body's not sent for GET, HEAD +// and DELETE HTTP methods. // -// A ReadSeekCloser wrapping an nonseekable io.Reader used in an API -// operation's input will prevent that operation being retried in the case of -// network errors, and cause operation requests to fail if the operation -// requires payload signing. -// -// Note: If using With S3 PutObject to stream an object upload The SDK's S3 -// Upload manager (s3manager.Uploader) provides support for streaming with the -// ability to retry network errors. +// Deprecated: Should only be used with io.ReadSeeker. If using for +// S3 PutObject to stream content use s3manager.Uploader instead. func ReadSeekCloser(r io.Reader) ReaderSeekerCloser { return ReaderSeekerCloser{r} } @@ -48,8 +43,7 @@ func IsReaderSeekable(r io.Reader) bool { // Read reads from the reader up to size of p. The number of bytes read, and // error if it occurred will be returned. // -// If the reader is not an io.Reader zero bytes read, and nil error will be -// returned. +// If the reader is not an io.Reader zero bytes read, and nil error will be returned. // // Performs the same functionality as io.Reader Read func (r ReaderSeekerCloser) Read(p []byte) (int, error) { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go/aws/version.go index 93797e613..e84bbc7f1 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/version.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.21.1" +const SDKVersion = "1.15.24" diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ast.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/ast.go deleted file mode 100644 index e83a99886..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ast.go +++ /dev/null @@ -1,120 +0,0 @@ -package ini - -// ASTKind represents different states in the parse table -// and the type of AST that is being constructed -type ASTKind int - -// ASTKind* is used in the parse table to transition between -// the different states -const ( - ASTKindNone = ASTKind(iota) - ASTKindStart - ASTKindExpr - ASTKindEqualExpr - ASTKindStatement - ASTKindSkipStatement - ASTKindExprStatement - ASTKindSectionStatement - ASTKindNestedSectionStatement - ASTKindCompletedNestedSectionStatement - ASTKindCommentStatement - ASTKindCompletedSectionStatement -) - -func (k ASTKind) String() string { - switch k { - case ASTKindNone: - return "none" - case ASTKindStart: - return "start" - case ASTKindExpr: - return "expr" - case ASTKindStatement: - return "stmt" - case ASTKindSectionStatement: - return "section_stmt" - case ASTKindExprStatement: - return "expr_stmt" - case ASTKindCommentStatement: - return "comment" - case ASTKindNestedSectionStatement: - return "nested_section_stmt" - case ASTKindCompletedSectionStatement: - return "completed_stmt" - case ASTKindSkipStatement: - return "skip" - default: - return "" - } -} - -// AST interface allows us to determine what kind of node we -// are on and casting may not need to be necessary. -// -// The root is always the first node in Children -type AST struct { - Kind ASTKind - Root Token - RootToken bool - Children []AST -} - -func newAST(kind ASTKind, root AST, children ...AST) AST { - return AST{ - Kind: kind, - Children: append([]AST{root}, children...), - } -} - -func newASTWithRootToken(kind ASTKind, root Token, children ...AST) AST { - return AST{ - Kind: kind, - Root: root, - RootToken: true, - Children: children, - } -} - -// AppendChild will append to the list of children an AST has. -func (a *AST) AppendChild(child AST) { - a.Children = append(a.Children, child) -} - -// GetRoot will return the root AST which can be the first entry -// in the children list or a token. -func (a *AST) GetRoot() AST { - if a.RootToken { - return *a - } - - if len(a.Children) == 0 { - return AST{} - } - - return a.Children[0] -} - -// GetChildren will return the current AST's list of children -func (a *AST) GetChildren() []AST { - if len(a.Children) == 0 { - return []AST{} - } - - if a.RootToken { - return a.Children - } - - return a.Children[1:] -} - -// SetChildren will set and override all children of the AST. -func (a *AST) SetChildren(children []AST) { - if a.RootToken { - a.Children = children - } else { - a.Children = append(a.Children[:1], children...) - } -} - -// Start is used to indicate the starting state of the parse table. -var Start = newAST(ASTKindStart, AST{}) diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go deleted file mode 100644 index 0895d53cb..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/comma_token.go +++ /dev/null @@ -1,11 +0,0 @@ -package ini - -var commaRunes = []rune(",") - -func isComma(b rune) bool { - return b == ',' -} - -func newCommaToken() Token { - return newToken(TokenComma, commaRunes, NoneType) -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go deleted file mode 100644 index 0b76999ba..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go +++ /dev/null @@ -1,35 +0,0 @@ -package ini - -// isComment will return whether or not the next byte(s) is a -// comment. -func isComment(b []rune) bool { - if len(b) == 0 { - return false - } - - switch b[0] { - case ';': - return true - case '#': - return true - } - - return false -} - -// newCommentToken will create a comment token and -// return how many bytes were read. -func newCommentToken(b []rune) (Token, int, error) { - i := 0 - for ; i < len(b); i++ { - if b[i] == '\n' { - break - } - - if len(b)-i > 2 && b[i] == '\r' && b[i+1] == '\n' { - break - } - } - - return newToken(TokenComment, b[:i], NoneType), i, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go deleted file mode 100644 index 25ce0fe13..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go +++ /dev/null @@ -1,29 +0,0 @@ -// Package ini is an LL(1) parser for configuration files. -// -// Example: -// sections, err := ini.OpenFile("/path/to/file") -// if err != nil { -// panic(err) -// } -// -// profile := "foo" -// section, ok := sections.GetSection(profile) -// if !ok { -// fmt.Printf("section %q could not be found", profile) -// } -// -// Below is the BNF that describes this parser -// Grammar: -// stmt -> value stmt' -// stmt' -> epsilon | op stmt -// value -> number | string | boolean | quoted_string -// -// section -> [ section' -// section' -> value section_close -// section_close -> ] -// -// SkipState will skip (NL WS)+ -// -// comment -> # comment' | ; comment' -// comment' -> epsilon | value -package ini diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go deleted file mode 100644 index 04345a54c..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/empty_token.go +++ /dev/null @@ -1,4 +0,0 @@ -package ini - -// emptyToken is used to satisfy the Token interface -var emptyToken = newToken(TokenNone, []rune{}, NoneType) diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go deleted file mode 100644 index 91ba2a59d..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/expression.go +++ /dev/null @@ -1,24 +0,0 @@ -package ini - -// newExpression will return an expression AST. -// Expr represents an expression -// -// grammar: -// expr -> string | number -func newExpression(tok Token) AST { - return newASTWithRootToken(ASTKindExpr, tok) -} - -func newEqualExpr(left AST, tok Token) AST { - return newASTWithRootToken(ASTKindEqualExpr, tok, left) -} - -// EqualExprKey will return a LHS value in the equal expr -func EqualExprKey(ast AST) string { - children := ast.GetChildren() - if len(children) == 0 || ast.Kind != ASTKindEqualExpr { - return "" - } - - return string(children[0].Root.Raw()) -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go deleted file mode 100644 index 8d462f77e..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/fuzz.go +++ /dev/null @@ -1,17 +0,0 @@ -// +build gofuzz - -package ini - -import ( - "bytes" -) - -func Fuzz(data []byte) int { - b := bytes.NewReader(data) - - if _, err := Parse(b); err != nil { - return 0 - } - - return 1 -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go deleted file mode 100644 index 3b0ca7afe..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini.go +++ /dev/null @@ -1,51 +0,0 @@ -package ini - -import ( - "io" - "os" - - "github.com/aws/aws-sdk-go/aws/awserr" -) - -// OpenFile takes a path to a given file, and will open and parse -// that file. -func OpenFile(path string) (Sections, error) { - f, err := os.Open(path) - if err != nil { - return Sections{}, awserr.New(ErrCodeUnableToReadFile, "unable to open file", err) - } - defer f.Close() - - return Parse(f) -} - -// Parse will parse the given file using the shared config -// visitor. -func Parse(f io.Reader) (Sections, error) { - tree, err := ParseAST(f) - if err != nil { - return Sections{}, err - } - - v := NewDefaultVisitor() - if err = Walk(tree, v); err != nil { - return Sections{}, err - } - - return v.Sections, nil -} - -// ParseBytes will parse the given bytes and return the parsed sections. -func ParseBytes(b []byte) (Sections, error) { - tree, err := ParseASTBytes(b) - if err != nil { - return Sections{}, err - } - - v := NewDefaultVisitor() - if err = Walk(tree, v); err != nil { - return Sections{}, err - } - - return v.Sections, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go deleted file mode 100644 index 582c024ad..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_lexer.go +++ /dev/null @@ -1,165 +0,0 @@ -package ini - -import ( - "bytes" - "io" - "io/ioutil" - - "github.com/aws/aws-sdk-go/aws/awserr" -) - -const ( - // ErrCodeUnableToReadFile is used when a file is failed to be - // opened or read from. - ErrCodeUnableToReadFile = "FailedRead" -) - -// TokenType represents the various different tokens types -type TokenType int - -func (t TokenType) String() string { - switch t { - case TokenNone: - return "none" - case TokenLit: - return "literal" - case TokenSep: - return "sep" - case TokenOp: - return "op" - case TokenWS: - return "ws" - case TokenNL: - return "newline" - case TokenComment: - return "comment" - case TokenComma: - return "comma" - default: - return "" - } -} - -// TokenType enums -const ( - TokenNone = TokenType(iota) - TokenLit - TokenSep - TokenComma - TokenOp - TokenWS - TokenNL - TokenComment -) - -type iniLexer struct{} - -// Tokenize will return a list of tokens during lexical analysis of the -// io.Reader. -func (l *iniLexer) Tokenize(r io.Reader) ([]Token, error) { - b, err := ioutil.ReadAll(r) - if err != nil { - return nil, awserr.New(ErrCodeUnableToReadFile, "unable to read file", err) - } - - return l.tokenize(b) -} - -func (l *iniLexer) tokenize(b []byte) ([]Token, error) { - runes := bytes.Runes(b) - var err error - n := 0 - tokenAmount := countTokens(runes) - tokens := make([]Token, tokenAmount) - count := 0 - - for len(runes) > 0 && count < tokenAmount { - switch { - case isWhitespace(runes[0]): - tokens[count], n, err = newWSToken(runes) - case isComma(runes[0]): - tokens[count], n = newCommaToken(), 1 - case isComment(runes): - tokens[count], n, err = newCommentToken(runes) - case isNewline(runes): - tokens[count], n, err = newNewlineToken(runes) - case isSep(runes): - tokens[count], n, err = newSepToken(runes) - case isOp(runes): - tokens[count], n, err = newOpToken(runes) - default: - tokens[count], n, err = newLitToken(runes) - } - - if err != nil { - return nil, err - } - - count++ - - runes = runes[n:] - } - - return tokens[:count], nil -} - -func countTokens(runes []rune) int { - count, n := 0, 0 - var err error - - for len(runes) > 0 { - switch { - case isWhitespace(runes[0]): - _, n, err = newWSToken(runes) - case isComma(runes[0]): - _, n = newCommaToken(), 1 - case isComment(runes): - _, n, err = newCommentToken(runes) - case isNewline(runes): - _, n, err = newNewlineToken(runes) - case isSep(runes): - _, n, err = newSepToken(runes) - case isOp(runes): - _, n, err = newOpToken(runes) - default: - _, n, err = newLitToken(runes) - } - - if err != nil { - return 0 - } - - count++ - runes = runes[n:] - } - - return count + 1 -} - -// Token indicates a metadata about a given value. -type Token struct { - t TokenType - ValueType ValueType - base int - raw []rune -} - -var emptyValue = Value{} - -func newToken(t TokenType, raw []rune, v ValueType) Token { - return Token{ - t: t, - raw: raw, - ValueType: v, - } -} - -// Raw return the raw runes that were consumed -func (tok Token) Raw() []rune { - return tok.raw -} - -// Type returns the token type -func (tok Token) Type() TokenType { - return tok.t -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go deleted file mode 100644 index e56dcee2f..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go +++ /dev/null @@ -1,349 +0,0 @@ -package ini - -import ( - "fmt" - "io" -) - -// State enums for the parse table -const ( - InvalidState = iota - // stmt -> value stmt' - StatementState - // stmt' -> MarkComplete | op stmt - StatementPrimeState - // value -> number | string | boolean | quoted_string - ValueState - // section -> [ section' - OpenScopeState - // section' -> value section_close - SectionState - // section_close -> ] - CloseScopeState - // SkipState will skip (NL WS)+ - SkipState - // SkipTokenState will skip any token and push the previous - // state onto the stack. - SkipTokenState - // comment -> # comment' | ; comment' - // comment' -> MarkComplete | value - CommentState - // MarkComplete state will complete statements and move that - // to the completed AST list - MarkCompleteState - // TerminalState signifies that the tokens have been fully parsed - TerminalState -) - -// parseTable is a state machine to dictate the grammar above. -var parseTable = map[ASTKind]map[TokenType]int{ - ASTKindStart: map[TokenType]int{ - TokenLit: StatementState, - TokenSep: OpenScopeState, - TokenWS: SkipTokenState, - TokenNL: SkipTokenState, - TokenComment: CommentState, - TokenNone: TerminalState, - }, - ASTKindCommentStatement: map[TokenType]int{ - TokenLit: StatementState, - TokenSep: OpenScopeState, - TokenWS: SkipTokenState, - TokenNL: SkipTokenState, - TokenComment: CommentState, - TokenNone: MarkCompleteState, - }, - ASTKindExpr: map[TokenType]int{ - TokenOp: StatementPrimeState, - TokenLit: ValueState, - TokenSep: OpenScopeState, - TokenWS: ValueState, - TokenNL: SkipState, - TokenComment: CommentState, - TokenNone: MarkCompleteState, - }, - ASTKindEqualExpr: map[TokenType]int{ - TokenLit: ValueState, - TokenWS: SkipTokenState, - TokenNL: SkipState, - }, - ASTKindStatement: map[TokenType]int{ - TokenLit: SectionState, - TokenSep: CloseScopeState, - TokenWS: SkipTokenState, - TokenNL: SkipTokenState, - TokenComment: CommentState, - TokenNone: MarkCompleteState, - }, - ASTKindExprStatement: map[TokenType]int{ - TokenLit: ValueState, - TokenSep: OpenScopeState, - TokenOp: ValueState, - TokenWS: ValueState, - TokenNL: MarkCompleteState, - TokenComment: CommentState, - TokenNone: TerminalState, - TokenComma: SkipState, - }, - ASTKindSectionStatement: map[TokenType]int{ - TokenLit: SectionState, - TokenOp: SectionState, - TokenSep: CloseScopeState, - TokenWS: SectionState, - TokenNL: SkipTokenState, - }, - ASTKindCompletedSectionStatement: map[TokenType]int{ - TokenWS: SkipTokenState, - TokenNL: SkipTokenState, - TokenLit: StatementState, - TokenSep: OpenScopeState, - TokenComment: CommentState, - TokenNone: MarkCompleteState, - }, - ASTKindSkipStatement: map[TokenType]int{ - TokenLit: StatementState, - TokenSep: OpenScopeState, - TokenWS: SkipTokenState, - TokenNL: SkipTokenState, - TokenComment: CommentState, - TokenNone: TerminalState, - }, -} - -// ParseAST will parse input from an io.Reader using -// an LL(1) parser. -func ParseAST(r io.Reader) ([]AST, error) { - lexer := iniLexer{} - tokens, err := lexer.Tokenize(r) - if err != nil { - return []AST{}, err - } - - return parse(tokens) -} - -// ParseASTBytes will parse input from a byte slice using -// an LL(1) parser. -func ParseASTBytes(b []byte) ([]AST, error) { - lexer := iniLexer{} - tokens, err := lexer.tokenize(b) - if err != nil { - return []AST{}, err - } - - return parse(tokens) -} - -func parse(tokens []Token) ([]AST, error) { - start := Start - stack := newParseStack(3, len(tokens)) - - stack.Push(start) - s := newSkipper() - -loop: - for stack.Len() > 0 { - k := stack.Pop() - - var tok Token - if len(tokens) == 0 { - // this occurs when all the tokens have been processed - // but reduction of what's left on the stack needs to - // occur. - tok = emptyToken - } else { - tok = tokens[0] - } - - step := parseTable[k.Kind][tok.Type()] - if s.ShouldSkip(tok) { - // being in a skip state with no tokens will break out of - // the parse loop since there is nothing left to process. - if len(tokens) == 0 { - break loop - } - - step = SkipTokenState - } - - switch step { - case TerminalState: - // Finished parsing. Push what should be the last - // statement to the stack. If there is anything left - // on the stack, an error in parsing has occurred. - if k.Kind != ASTKindStart { - stack.MarkComplete(k) - } - break loop - case SkipTokenState: - // When skipping a token, the previous state was popped off the stack. - // To maintain the correct state, the previous state will be pushed - // onto the stack. - stack.Push(k) - case StatementState: - if k.Kind != ASTKindStart { - stack.MarkComplete(k) - } - expr := newExpression(tok) - stack.Push(expr) - case StatementPrimeState: - if tok.Type() != TokenOp { - stack.MarkComplete(k) - continue - } - - if k.Kind != ASTKindExpr { - return nil, NewParseError( - fmt.Sprintf("invalid expression: expected Expr type, but found %T type", k), - ) - } - - k = trimSpaces(k) - expr := newEqualExpr(k, tok) - stack.Push(expr) - case ValueState: - // ValueState requires the previous state to either be an equal expression - // or an expression statement. - // - // This grammar occurs when the RHS is a number, word, or quoted string. - // equal_expr -> lit op equal_expr' - // equal_expr' -> number | string | quoted_string - // quoted_string -> " quoted_string' - // quoted_string' -> string quoted_string_end - // quoted_string_end -> " - // - // otherwise - // expr_stmt -> equal_expr (expr_stmt')* - // expr_stmt' -> ws S | op S | MarkComplete - // S -> equal_expr' expr_stmt' - switch k.Kind { - case ASTKindEqualExpr: - // assiging a value to some key - k.AppendChild(newExpression(tok)) - stack.Push(newExprStatement(k)) - case ASTKindExpr: - k.Root.raw = append(k.Root.raw, tok.Raw()...) - stack.Push(k) - case ASTKindExprStatement: - root := k.GetRoot() - children := root.GetChildren() - if len(children) == 0 { - return nil, NewParseError( - fmt.Sprintf("invalid expression: AST contains no children %s", k.Kind), - ) - } - - rhs := children[len(children)-1] - - if rhs.Root.ValueType != QuotedStringType { - rhs.Root.ValueType = StringType - rhs.Root.raw = append(rhs.Root.raw, tok.Raw()...) - - } - - children[len(children)-1] = rhs - k.SetChildren(children) - - stack.Push(k) - } - case OpenScopeState: - if !runeCompare(tok.Raw(), openBrace) { - return nil, NewParseError("expected '['") - } - - stmt := newStatement() - stack.Push(stmt) - case CloseScopeState: - if !runeCompare(tok.Raw(), closeBrace) { - return nil, NewParseError("expected ']'") - } - - k = trimSpaces(k) - stack.Push(newCompletedSectionStatement(k)) - case SectionState: - var stmt AST - - switch k.Kind { - case ASTKindStatement: - // If there are multiple literals inside of a scope declaration, - // then the current token's raw value will be appended to the Name. - // - // This handles cases like [ profile default ] - // - // k will represent a SectionStatement with the children representing - // the label of the section - stmt = newSectionStatement(tok) - case ASTKindSectionStatement: - k.Root.raw = append(k.Root.raw, tok.Raw()...) - stmt = k - default: - return nil, NewParseError( - fmt.Sprintf("invalid statement: expected statement: %v", k.Kind), - ) - } - - stack.Push(stmt) - case MarkCompleteState: - if k.Kind != ASTKindStart { - stack.MarkComplete(k) - } - - if stack.Len() == 0 { - stack.Push(start) - } - case SkipState: - stack.Push(newSkipStatement(k)) - s.Skip() - case CommentState: - if k.Kind == ASTKindStart { - stack.Push(k) - } else { - stack.MarkComplete(k) - } - - stmt := newCommentStatement(tok) - stack.Push(stmt) - default: - return nil, NewParseError( - fmt.Sprintf("invalid state with ASTKind %v and TokenType %v", - k, tok.Type())) - } - - if len(tokens) > 0 { - tokens = tokens[1:] - } - } - - // this occurs when a statement has not been completed - if stack.top > 1 { - return nil, NewParseError(fmt.Sprintf("incomplete ini expression")) - } - - // returns a sublist which excludes the start symbol - return stack.List(), nil -} - -// trimSpaces will trim spaces on the left and right hand side of -// the literal. -func trimSpaces(k AST) AST { - // trim left hand side of spaces - for i := 0; i < len(k.Root.raw); i++ { - if !isWhitespace(k.Root.raw[i]) { - break - } - - k.Root.raw = k.Root.raw[1:] - i-- - } - - // trim right hand side of spaces - for i := len(k.Root.raw) - 1; i >= 0; i-- { - if !isWhitespace(k.Root.raw[i]) { - break - } - - k.Root.raw = k.Root.raw[:len(k.Root.raw)-1] - } - - return k -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go deleted file mode 100644 index 24df543d3..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go +++ /dev/null @@ -1,324 +0,0 @@ -package ini - -import ( - "fmt" - "strconv" - "strings" -) - -var ( - runesTrue = []rune("true") - runesFalse = []rune("false") -) - -var literalValues = [][]rune{ - runesTrue, - runesFalse, -} - -func isBoolValue(b []rune) bool { - for _, lv := range literalValues { - if isLitValue(lv, b) { - return true - } - } - return false -} - -func isLitValue(want, have []rune) bool { - if len(have) < len(want) { - return false - } - - for i := 0; i < len(want); i++ { - if want[i] != have[i] { - return false - } - } - - return true -} - -// isNumberValue will return whether not the leading characters in -// a byte slice is a number. A number is delimited by whitespace or -// the newline token. -// -// A number is defined to be in a binary, octal, decimal (int | float), hex format, -// or in scientific notation. -func isNumberValue(b []rune) bool { - negativeIndex := 0 - helper := numberHelper{} - needDigit := false - - for i := 0; i < len(b); i++ { - negativeIndex++ - - switch b[i] { - case '-': - if helper.IsNegative() || negativeIndex != 1 { - return false - } - helper.Determine(b[i]) - needDigit = true - continue - case 'e', 'E': - if err := helper.Determine(b[i]); err != nil { - return false - } - negativeIndex = 0 - needDigit = true - continue - case 'b': - if helper.numberFormat == hex { - break - } - fallthrough - case 'o', 'x': - needDigit = true - if i == 0 { - return false - } - - fallthrough - case '.': - if err := helper.Determine(b[i]); err != nil { - return false - } - needDigit = true - continue - } - - if i > 0 && (isNewline(b[i:]) || isWhitespace(b[i])) { - return !needDigit - } - - if !helper.CorrectByte(b[i]) { - return false - } - needDigit = false - } - - return !needDigit -} - -func isValid(b []rune) (bool, int, error) { - if len(b) == 0 { - // TODO: should probably return an error - return false, 0, nil - } - - return isValidRune(b[0]), 1, nil -} - -func isValidRune(r rune) bool { - return r != ':' && r != '=' && r != '[' && r != ']' && r != ' ' && r != '\n' -} - -// ValueType is an enum that will signify what type -// the Value is -type ValueType int - -func (v ValueType) String() string { - switch v { - case NoneType: - return "NONE" - case DecimalType: - return "FLOAT" - case IntegerType: - return "INT" - case StringType: - return "STRING" - case BoolType: - return "BOOL" - } - - return "" -} - -// ValueType enums -const ( - NoneType = ValueType(iota) - DecimalType - IntegerType - StringType - QuotedStringType - BoolType -) - -// Value is a union container -type Value struct { - Type ValueType - raw []rune - - integer int64 - decimal float64 - boolean bool - str string -} - -func newValue(t ValueType, base int, raw []rune) (Value, error) { - v := Value{ - Type: t, - raw: raw, - } - var err error - - switch t { - case DecimalType: - v.decimal, err = strconv.ParseFloat(string(raw), 64) - case IntegerType: - if base != 10 { - raw = raw[2:] - } - - v.integer, err = strconv.ParseInt(string(raw), base, 64) - case StringType: - v.str = string(raw) - case QuotedStringType: - v.str = string(raw[1 : len(raw)-1]) - case BoolType: - v.boolean = runeCompare(v.raw, runesTrue) - } - - // issue 2253 - // - // if the value trying to be parsed is too large, then we will use - // the 'StringType' and raw value instead. - if nerr, ok := err.(*strconv.NumError); ok && nerr.Err == strconv.ErrRange { - v.Type = StringType - v.str = string(raw) - err = nil - } - - return v, err -} - -// Append will append values and change the type to a string -// type. -func (v *Value) Append(tok Token) { - r := tok.Raw() - if v.Type != QuotedStringType { - v.Type = StringType - r = tok.raw[1 : len(tok.raw)-1] - } - if tok.Type() != TokenLit { - v.raw = append(v.raw, tok.Raw()...) - } else { - v.raw = append(v.raw, r...) - } -} - -func (v Value) String() string { - switch v.Type { - case DecimalType: - return fmt.Sprintf("decimal: %f", v.decimal) - case IntegerType: - return fmt.Sprintf("integer: %d", v.integer) - case StringType: - return fmt.Sprintf("string: %s", string(v.raw)) - case QuotedStringType: - return fmt.Sprintf("quoted string: %s", string(v.raw)) - case BoolType: - return fmt.Sprintf("bool: %t", v.boolean) - default: - return "union not set" - } -} - -func newLitToken(b []rune) (Token, int, error) { - n := 0 - var err error - - token := Token{} - if b[0] == '"' { - n, err = getStringValue(b) - if err != nil { - return token, n, err - } - - token = newToken(TokenLit, b[:n], QuotedStringType) - } else if isNumberValue(b) { - var base int - base, n, err = getNumericalValue(b) - if err != nil { - return token, 0, err - } - - value := b[:n] - vType := IntegerType - if contains(value, '.') || hasExponent(value) { - vType = DecimalType - } - token = newToken(TokenLit, value, vType) - token.base = base - } else if isBoolValue(b) { - n, err = getBoolValue(b) - - token = newToken(TokenLit, b[:n], BoolType) - } else { - n, err = getValue(b) - token = newToken(TokenLit, b[:n], StringType) - } - - return token, n, err -} - -// IntValue returns an integer value -func (v Value) IntValue() int64 { - return v.integer -} - -// FloatValue returns a float value -func (v Value) FloatValue() float64 { - return v.decimal -} - -// BoolValue returns a bool value -func (v Value) BoolValue() bool { - return v.boolean -} - -func isTrimmable(r rune) bool { - switch r { - case '\n', ' ': - return true - } - return false -} - -// StringValue returns the string value -func (v Value) StringValue() string { - switch v.Type { - case StringType: - return strings.TrimFunc(string(v.raw), isTrimmable) - case QuotedStringType: - // preserve all characters in the quotes - return string(removeEscapedCharacters(v.raw[1 : len(v.raw)-1])) - default: - return strings.TrimFunc(string(v.raw), isTrimmable) - } -} - -func contains(runes []rune, c rune) bool { - for i := 0; i < len(runes); i++ { - if runes[i] == c { - return true - } - } - - return false -} - -func runeCompare(v1 []rune, v2 []rune) bool { - if len(v1) != len(v2) { - return false - } - - for i := 0; i < len(v1); i++ { - if v1[i] != v2[i] { - return false - } - } - - return true -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go deleted file mode 100644 index e52ac399f..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/newline_token.go +++ /dev/null @@ -1,30 +0,0 @@ -package ini - -func isNewline(b []rune) bool { - if len(b) == 0 { - return false - } - - if b[0] == '\n' { - return true - } - - if len(b) < 2 { - return false - } - - return b[0] == '\r' && b[1] == '\n' -} - -func newNewlineToken(b []rune) (Token, int, error) { - i := 1 - if b[0] == '\r' && isNewline(b[1:]) { - i++ - } - - if !isNewline([]rune(b[:i])) { - return emptyToken, 0, NewParseError("invalid new line token") - } - - return newToken(TokenNL, b[:i], NoneType), i, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/number_helper.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/number_helper.go deleted file mode 100644 index a45c0bc56..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/number_helper.go +++ /dev/null @@ -1,152 +0,0 @@ -package ini - -import ( - "bytes" - "fmt" - "strconv" -) - -const ( - none = numberFormat(iota) - binary - octal - decimal - hex - exponent -) - -type numberFormat int - -// numberHelper is used to dictate what format a number is in -// and what to do for negative values. Since -1e-4 is a valid -// number, we cannot just simply check for duplicate negatives. -type numberHelper struct { - numberFormat numberFormat - - negative bool - negativeExponent bool -} - -func (b numberHelper) Exists() bool { - return b.numberFormat != none -} - -func (b numberHelper) IsNegative() bool { - return b.negative || b.negativeExponent -} - -func (b *numberHelper) Determine(c rune) error { - if b.Exists() { - return NewParseError(fmt.Sprintf("multiple number formats: 0%v", string(c))) - } - - switch c { - case 'b': - b.numberFormat = binary - case 'o': - b.numberFormat = octal - case 'x': - b.numberFormat = hex - case 'e', 'E': - b.numberFormat = exponent - case '-': - if b.numberFormat != exponent { - b.negative = true - } else { - b.negativeExponent = true - } - case '.': - b.numberFormat = decimal - default: - return NewParseError(fmt.Sprintf("invalid number character: %v", string(c))) - } - - return nil -} - -func (b numberHelper) CorrectByte(c rune) bool { - switch { - case b.numberFormat == binary: - if !isBinaryByte(c) { - return false - } - case b.numberFormat == octal: - if !isOctalByte(c) { - return false - } - case b.numberFormat == hex: - if !isHexByte(c) { - return false - } - case b.numberFormat == decimal: - if !isDigit(c) { - return false - } - case b.numberFormat == exponent: - if !isDigit(c) { - return false - } - case b.negativeExponent: - if !isDigit(c) { - return false - } - case b.negative: - if !isDigit(c) { - return false - } - default: - if !isDigit(c) { - return false - } - } - - return true -} - -func (b numberHelper) Base() int { - switch b.numberFormat { - case binary: - return 2 - case octal: - return 8 - case hex: - return 16 - default: - return 10 - } -} - -func (b numberHelper) String() string { - buf := bytes.Buffer{} - i := 0 - - switch b.numberFormat { - case binary: - i++ - buf.WriteString(strconv.Itoa(i) + ": binary format\n") - case octal: - i++ - buf.WriteString(strconv.Itoa(i) + ": octal format\n") - case hex: - i++ - buf.WriteString(strconv.Itoa(i) + ": hex format\n") - case exponent: - i++ - buf.WriteString(strconv.Itoa(i) + ": exponent format\n") - default: - i++ - buf.WriteString(strconv.Itoa(i) + ": integer format\n") - } - - if b.negative { - i++ - buf.WriteString(strconv.Itoa(i) + ": negative format\n") - } - - if b.negativeExponent { - i++ - buf.WriteString(strconv.Itoa(i) + ": negative exponent format\n") - } - - return buf.String() -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go deleted file mode 100644 index 8a84c7cbe..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/op_tokens.go +++ /dev/null @@ -1,39 +0,0 @@ -package ini - -import ( - "fmt" -) - -var ( - equalOp = []rune("=") - equalColonOp = []rune(":") -) - -func isOp(b []rune) bool { - if len(b) == 0 { - return false - } - - switch b[0] { - case '=': - return true - case ':': - return true - default: - return false - } -} - -func newOpToken(b []rune) (Token, int, error) { - tok := Token{} - - switch b[0] { - case '=': - tok = newToken(TokenOp, equalOp, NoneType) - case ':': - tok = newToken(TokenOp, equalColonOp, NoneType) - default: - return tok, 0, NewParseError(fmt.Sprintf("unexpected op type, %v", b[0])) - } - return tok, 1, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go deleted file mode 100644 index 457287019..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_error.go +++ /dev/null @@ -1,43 +0,0 @@ -package ini - -import "fmt" - -const ( - // ErrCodeParseError is returned when a parsing error - // has occurred. - ErrCodeParseError = "INIParseError" -) - -// ParseError is an error which is returned during any part of -// the parsing process. -type ParseError struct { - msg string -} - -// NewParseError will return a new ParseError where message -// is the description of the error. -func NewParseError(message string) *ParseError { - return &ParseError{ - msg: message, - } -} - -// Code will return the ErrCodeParseError -func (err *ParseError) Code() string { - return ErrCodeParseError -} - -// Message returns the error's message -func (err *ParseError) Message() string { - return err.msg -} - -// OrigError return nothing since there will never be any -// original error. -func (err *ParseError) OrigError() error { - return nil -} - -func (err *ParseError) Error() string { - return fmt.Sprintf("%s: %s", err.Code(), err.Message()) -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_stack.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_stack.go deleted file mode 100644 index 7f01cf7c7..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/parse_stack.go +++ /dev/null @@ -1,60 +0,0 @@ -package ini - -import ( - "bytes" - "fmt" -) - -// ParseStack is a stack that contains a container, the stack portion, -// and the list which is the list of ASTs that have been successfully -// parsed. -type ParseStack struct { - top int - container []AST - list []AST - index int -} - -func newParseStack(sizeContainer, sizeList int) ParseStack { - return ParseStack{ - container: make([]AST, sizeContainer), - list: make([]AST, sizeList), - } -} - -// Pop will return and truncate the last container element. -func (s *ParseStack) Pop() AST { - s.top-- - return s.container[s.top] -} - -// Push will add the new AST to the container -func (s *ParseStack) Push(ast AST) { - s.container[s.top] = ast - s.top++ -} - -// MarkComplete will append the AST to the list of completed statements -func (s *ParseStack) MarkComplete(ast AST) { - s.list[s.index] = ast - s.index++ -} - -// List will return the completed statements -func (s ParseStack) List() []AST { - return s.list[:s.index] -} - -// Len will return the length of the container -func (s *ParseStack) Len() int { - return s.top -} - -func (s ParseStack) String() string { - buf := bytes.Buffer{} - for i, node := range s.list { - buf.WriteString(fmt.Sprintf("%d: %v\n", i+1, node)) - } - - return buf.String() -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go deleted file mode 100644 index f82095ba2..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/sep_tokens.go +++ /dev/null @@ -1,41 +0,0 @@ -package ini - -import ( - "fmt" -) - -var ( - emptyRunes = []rune{} -) - -func isSep(b []rune) bool { - if len(b) == 0 { - return false - } - - switch b[0] { - case '[', ']': - return true - default: - return false - } -} - -var ( - openBrace = []rune("[") - closeBrace = []rune("]") -) - -func newSepToken(b []rune) (Token, int, error) { - tok := Token{} - - switch b[0] { - case '[': - tok = newToken(TokenSep, openBrace, NoneType) - case ']': - tok = newToken(TokenSep, closeBrace, NoneType) - default: - return tok, 0, NewParseError(fmt.Sprintf("unexpected sep type, %v", b[0])) - } - return tok, 1, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go deleted file mode 100644 index 6bb696447..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go +++ /dev/null @@ -1,45 +0,0 @@ -package ini - -// skipper is used to skip certain blocks of an ini file. -// Currently skipper is used to skip nested blocks of ini -// files. See example below -// -// [ foo ] -// nested = ; this section will be skipped -// a=b -// c=d -// bar=baz ; this will be included -type skipper struct { - shouldSkip bool - TokenSet bool - prevTok Token -} - -func newSkipper() skipper { - return skipper{ - prevTok: emptyToken, - } -} - -func (s *skipper) ShouldSkip(tok Token) bool { - if s.shouldSkip && - s.prevTok.Type() == TokenNL && - tok.Type() != TokenWS { - - s.Continue() - return false - } - s.prevTok = tok - - return s.shouldSkip -} - -func (s *skipper) Skip() { - s.shouldSkip = true - s.prevTok = emptyToken -} - -func (s *skipper) Continue() { - s.shouldSkip = false - s.prevTok = emptyToken -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go deleted file mode 100644 index 18f3fe893..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go +++ /dev/null @@ -1,35 +0,0 @@ -package ini - -// Statement is an empty AST mostly used for transitioning states. -func newStatement() AST { - return newAST(ASTKindStatement, AST{}) -} - -// SectionStatement represents a section AST -func newSectionStatement(tok Token) AST { - return newASTWithRootToken(ASTKindSectionStatement, tok) -} - -// ExprStatement represents a completed expression AST -func newExprStatement(ast AST) AST { - return newAST(ASTKindExprStatement, ast) -} - -// CommentStatement represents a comment in the ini definition. -// -// grammar: -// comment -> #comment' | ;comment' -// comment' -> epsilon | value -func newCommentStatement(tok Token) AST { - return newAST(ASTKindCommentStatement, newExpression(tok)) -} - -// CompletedSectionStatement represents a completed section -func newCompletedSectionStatement(ast AST) AST { - return newAST(ASTKindCompletedSectionStatement, ast) -} - -// SkipStatement is used to skip whole statements -func newSkipStatement(ast AST) AST { - return newAST(ASTKindSkipStatement, ast) -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go deleted file mode 100644 index 305999d29..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/value_util.go +++ /dev/null @@ -1,284 +0,0 @@ -package ini - -import ( - "fmt" -) - -// getStringValue will return a quoted string and the amount -// of bytes read -// -// an error will be returned if the string is not properly formatted -func getStringValue(b []rune) (int, error) { - if b[0] != '"' { - return 0, NewParseError("strings must start with '\"'") - } - - endQuote := false - i := 1 - - for ; i < len(b) && !endQuote; i++ { - if escaped := isEscaped(b[:i], b[i]); b[i] == '"' && !escaped { - endQuote = true - break - } else if escaped { - /*c, err := getEscapedByte(b[i]) - if err != nil { - return 0, err - } - - b[i-1] = c - b = append(b[:i], b[i+1:]...) - i--*/ - - continue - } - } - - if !endQuote { - return 0, NewParseError("missing '\"' in string value") - } - - return i + 1, nil -} - -// getBoolValue will return a boolean and the amount -// of bytes read -// -// an error will be returned if the boolean is not of a correct -// value -func getBoolValue(b []rune) (int, error) { - if len(b) < 4 { - return 0, NewParseError("invalid boolean value") - } - - n := 0 - for _, lv := range literalValues { - if len(lv) > len(b) { - continue - } - - if isLitValue(lv, b) { - n = len(lv) - } - } - - if n == 0 { - return 0, NewParseError("invalid boolean value") - } - - return n, nil -} - -// getNumericalValue will return a numerical string, the amount -// of bytes read, and the base of the number -// -// an error will be returned if the number is not of a correct -// value -func getNumericalValue(b []rune) (int, int, error) { - if !isDigit(b[0]) { - return 0, 0, NewParseError("invalid digit value") - } - - i := 0 - helper := numberHelper{} - -loop: - for negativeIndex := 0; i < len(b); i++ { - negativeIndex++ - - if !isDigit(b[i]) { - switch b[i] { - case '-': - if helper.IsNegative() || negativeIndex != 1 { - return 0, 0, NewParseError("parse error '-'") - } - - n := getNegativeNumber(b[i:]) - i += (n - 1) - helper.Determine(b[i]) - continue - case '.': - if err := helper.Determine(b[i]); err != nil { - return 0, 0, err - } - case 'e', 'E': - if err := helper.Determine(b[i]); err != nil { - return 0, 0, err - } - - negativeIndex = 0 - case 'b': - if helper.numberFormat == hex { - break - } - fallthrough - case 'o', 'x': - if i == 0 && b[i] != '0' { - return 0, 0, NewParseError("incorrect base format, expected leading '0'") - } - - if i != 1 { - return 0, 0, NewParseError(fmt.Sprintf("incorrect base format found %s at %d index", string(b[i]), i)) - } - - if err := helper.Determine(b[i]); err != nil { - return 0, 0, err - } - default: - if isWhitespace(b[i]) { - break loop - } - - if isNewline(b[i:]) { - break loop - } - - if !(helper.numberFormat == hex && isHexByte(b[i])) { - if i+2 < len(b) && !isNewline(b[i:i+2]) { - return 0, 0, NewParseError("invalid numerical character") - } else if !isNewline([]rune{b[i]}) { - return 0, 0, NewParseError("invalid numerical character") - } - - break loop - } - } - } - } - - return helper.Base(), i, nil -} - -// isDigit will return whether or not something is an integer -func isDigit(b rune) bool { - return b >= '0' && b <= '9' -} - -func hasExponent(v []rune) bool { - return contains(v, 'e') || contains(v, 'E') -} - -func isBinaryByte(b rune) bool { - switch b { - case '0', '1': - return true - default: - return false - } -} - -func isOctalByte(b rune) bool { - switch b { - case '0', '1', '2', '3', '4', '5', '6', '7': - return true - default: - return false - } -} - -func isHexByte(b rune) bool { - if isDigit(b) { - return true - } - return (b >= 'A' && b <= 'F') || - (b >= 'a' && b <= 'f') -} - -func getValue(b []rune) (int, error) { - i := 0 - - for i < len(b) { - if isNewline(b[i:]) { - break - } - - if isOp(b[i:]) { - break - } - - valid, n, err := isValid(b[i:]) - if err != nil { - return 0, err - } - - if !valid { - break - } - - i += n - } - - return i, nil -} - -// getNegativeNumber will return a negative number from a -// byte slice. This will iterate through all characters until -// a non-digit has been found. -func getNegativeNumber(b []rune) int { - if b[0] != '-' { - return 0 - } - - i := 1 - for ; i < len(b); i++ { - if !isDigit(b[i]) { - return i - } - } - - return i -} - -// isEscaped will return whether or not the character is an escaped -// character. -func isEscaped(value []rune, b rune) bool { - if len(value) == 0 { - return false - } - - switch b { - case '\'': // single quote - case '"': // quote - case 'n': // newline - case 't': // tab - case '\\': // backslash - default: - return false - } - - return value[len(value)-1] == '\\' -} - -func getEscapedByte(b rune) (rune, error) { - switch b { - case '\'': // single quote - return '\'', nil - case '"': // quote - return '"', nil - case 'n': // newline - return '\n', nil - case 't': // table - return '\t', nil - case '\\': // backslash - return '\\', nil - default: - return b, NewParseError(fmt.Sprintf("invalid escaped character %c", b)) - } -} - -func removeEscapedCharacters(b []rune) []rune { - for i := 0; i < len(b); i++ { - if isEscaped(b[:i], b[i]) { - c, err := getEscapedByte(b[i]) - if err != nil { - return b - } - - b[i-1] = c - b = append(b[:i], b[i+1:]...) - i-- - } - } - - return b -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go deleted file mode 100644 index 94841c324..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go +++ /dev/null @@ -1,166 +0,0 @@ -package ini - -import ( - "fmt" - "sort" -) - -// Visitor is an interface used by walkers that will -// traverse an array of ASTs. -type Visitor interface { - VisitExpr(AST) error - VisitStatement(AST) error -} - -// DefaultVisitor is used to visit statements and expressions -// and ensure that they are both of the correct format. -// In addition, upon visiting this will build sections and populate -// the Sections field which can be used to retrieve profile -// configuration. -type DefaultVisitor struct { - scope string - Sections Sections -} - -// NewDefaultVisitor return a DefaultVisitor -func NewDefaultVisitor() *DefaultVisitor { - return &DefaultVisitor{ - Sections: Sections{ - container: map[string]Section{}, - }, - } -} - -// VisitExpr visits expressions... -func (v *DefaultVisitor) VisitExpr(expr AST) error { - t := v.Sections.container[v.scope] - if t.values == nil { - t.values = values{} - } - - switch expr.Kind { - case ASTKindExprStatement: - opExpr := expr.GetRoot() - switch opExpr.Kind { - case ASTKindEqualExpr: - children := opExpr.GetChildren() - if len(children) <= 1 { - return NewParseError("unexpected token type") - } - - rhs := children[1] - - if rhs.Root.Type() != TokenLit { - return NewParseError("unexpected token type") - } - - key := EqualExprKey(opExpr) - v, err := newValue(rhs.Root.ValueType, rhs.Root.base, rhs.Root.Raw()) - if err != nil { - return err - } - - t.values[key] = v - default: - return NewParseError(fmt.Sprintf("unsupported expression %v", expr)) - } - default: - return NewParseError(fmt.Sprintf("unsupported expression %v", expr)) - } - - v.Sections.container[v.scope] = t - return nil -} - -// VisitStatement visits statements... -func (v *DefaultVisitor) VisitStatement(stmt AST) error { - switch stmt.Kind { - case ASTKindCompletedSectionStatement: - child := stmt.GetRoot() - if child.Kind != ASTKindSectionStatement { - return NewParseError(fmt.Sprintf("unsupported child statement: %T", child)) - } - - name := string(child.Root.Raw()) - v.Sections.container[name] = Section{} - v.scope = name - default: - return NewParseError(fmt.Sprintf("unsupported statement: %s", stmt.Kind)) - } - - return nil -} - -// Sections is a map of Section structures that represent -// a configuration. -type Sections struct { - container map[string]Section -} - -// GetSection will return section p. If section p does not exist, -// false will be returned in the second parameter. -func (t Sections) GetSection(p string) (Section, bool) { - v, ok := t.container[p] - return v, ok -} - -// values represents a map of union values. -type values map[string]Value - -// List will return a list of all sections that were successfully -// parsed. -func (t Sections) List() []string { - keys := make([]string, len(t.container)) - i := 0 - for k := range t.container { - keys[i] = k - i++ - } - - sort.Strings(keys) - return keys -} - -// Section contains a name and values. This represent -// a sectioned entry in a configuration file. -type Section struct { - Name string - values values -} - -// Has will return whether or not an entry exists in a given section -func (t Section) Has(k string) bool { - _, ok := t.values[k] - return ok -} - -// ValueType will returned what type the union is set to. If -// k was not found, the NoneType will be returned. -func (t Section) ValueType(k string) (ValueType, bool) { - v, ok := t.values[k] - return v.Type, ok -} - -// Bool returns a bool value at k -func (t Section) Bool(k string) bool { - return t.values[k].BoolValue() -} - -// Int returns an integer value at k -func (t Section) Int(k string) int64 { - return t.values[k].IntValue() -} - -// Float64 returns a float value at k -func (t Section) Float64(k string) float64 { - return t.values[k].FloatValue() -} - -// String returns the string value at k -func (t Section) String(k string) string { - _, ok := t.values[k] - if !ok { - return "" - } - return t.values[k].StringValue() -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go deleted file mode 100644 index 99915f7f7..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/walker.go +++ /dev/null @@ -1,25 +0,0 @@ -package ini - -// Walk will traverse the AST using the v, the Visitor. -func Walk(tree []AST, v Visitor) error { - for _, node := range tree { - switch node.Kind { - case ASTKindExpr, - ASTKindExprStatement: - - if err := v.VisitExpr(node); err != nil { - return err - } - case ASTKindStatement, - ASTKindCompletedSectionStatement, - ASTKindNestedSectionStatement, - ASTKindCompletedNestedSectionStatement: - - if err := v.VisitStatement(node); err != nil { - return err - } - } - } - - return nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go b/vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go deleted file mode 100644 index 7ffb4ae06..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/ini/ws_token.go +++ /dev/null @@ -1,24 +0,0 @@ -package ini - -import ( - "unicode" -) - -// isWhitespace will return whether or not the character is -// a whitespace character. -// -// Whitespace is defined as a space or tab. -func isWhitespace(c rune) bool { - return unicode.IsSpace(c) && c != '\n' && c != '\r' -} - -func newWSToken(b []rune) (Token, int, error) { - i := 0 - for ; i < len(b); i++ { - if !isWhitespace(b[i]) { - break - } - } - - return newToken(TokenWS, b[:i], NoneType), i, nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go b/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go deleted file mode 100644 index 7da8a49ce..000000000 --- a/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go +++ /dev/null @@ -1,12 +0,0 @@ -package shareddefaults - -const ( - // ECSCredsProviderEnvVar is an environmental variable key used to - // determine which path needs to be hit. - ECSCredsProviderEnvVar = "AWS_CONTAINER_CREDENTIALS_RELATIVE_URI" -) - -// ECSContainerCredentialsURI is the endpoint to retrieve container -// credentials. This can be overridden to test to ensure the credential process -// is behaving correctly. -var ECSContainerCredentialsURI = "http://169.254.170.2" diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go index 50c5ed760..3104e6ce4 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/build.go @@ -21,8 +21,7 @@ func Build(r *request.Request) { "Version": {r.ClientInfo.APIVersion}, } if err := queryutil.Parse(body, r.Params, true); err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, - "failed encoding EC2 Query request", err) + r.Error = awserr.New("SerializationError", "failed encoding EC2 Query request", err) } if !r.IsPresigned() { diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/unmarshal.go index 105d732f9..095e97ccf 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/unmarshal.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query/unmarshal.go @@ -4,6 +4,7 @@ package ec2query import ( "encoding/xml" + "io" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/request" @@ -26,12 +27,7 @@ func Unmarshal(r *request.Request) { decoder := xml.NewDecoder(r.HTTPResponse.Body) err := xmlutil.UnmarshalXML(r.Data, decoder, "") if err != nil { - r.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, - "failed decoding EC2 Query response", err), - r.HTTPResponse.StatusCode, - r.RequestID, - ) + r.Error = awserr.New("SerializationError", "failed decoding EC2 Query response", err) return } } @@ -39,11 +35,7 @@ func Unmarshal(r *request.Request) { // UnmarshalMeta unmarshals response headers for the EC2 protocol. func UnmarshalMeta(r *request.Request) { - r.RequestID = r.HTTPResponse.Header.Get("X-Amzn-Requestid") - if r.RequestID == "" { - // Alternative version of request id in the header - r.RequestID = r.HTTPResponse.Header.Get("X-Amz-Request-Id") - } + // TODO implement unmarshaling of request IDs } type xmlErrorResponse struct { @@ -57,21 +49,15 @@ type xmlErrorResponse struct { func UnmarshalError(r *request.Request) { defer r.HTTPResponse.Body.Close() - var respErr xmlErrorResponse - err := xmlutil.UnmarshalXMLError(&respErr, r.HTTPResponse.Body) - if err != nil { + resp := &xmlErrorResponse{} + err := xml.NewDecoder(r.HTTPResponse.Body).Decode(resp) + if err != nil && err != io.EOF { + r.Error = awserr.New("SerializationError", "failed decoding EC2 Query error response", err) + } else { r.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, - "failed to unmarshal error message", err), + awserr.New(resp.Code, resp.Message, nil), r.HTTPResponse.StatusCode, - r.RequestID, + resp.RequestID, ) - return } - - r.Error = awserr.NewRequestFailure( - awserr.New(respErr.Code, respErr.Message, nil), - r.HTTPResponse.StatusCode, - respErr.RequestID, - ) } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go deleted file mode 100644 index d7d42db0a..000000000 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go +++ /dev/null @@ -1,68 +0,0 @@ -package protocol - -import ( - "strings" - - "github.com/aws/aws-sdk-go/aws/request" -) - -// ValidateEndpointHostHandler is a request handler that will validate the -// request endpoint's hosts is a valid RFC 3986 host. -var ValidateEndpointHostHandler = request.NamedHandler{ - Name: "awssdk.protocol.ValidateEndpointHostHandler", - Fn: func(r *request.Request) { - err := ValidateEndpointHost(r.Operation.Name, r.HTTPRequest.URL.Host) - if err != nil { - r.Error = err - } - }, -} - -// ValidateEndpointHost validates that the host string passed in is a valid RFC -// 3986 host. Returns error if the host is not valid. -func ValidateEndpointHost(opName, host string) error { - paramErrs := request.ErrInvalidParams{Context: opName} - labels := strings.Split(host, ".") - - for i, label := range labels { - if i == len(labels)-1 && len(label) == 0 { - // Allow trailing dot for FQDN hosts. - continue - } - - if !ValidHostLabel(label) { - paramErrs.Add(request.NewErrParamFormat( - "endpoint host label", "[a-zA-Z0-9-]{1,63}", label)) - } - } - - if len(host) > 255 { - paramErrs.Add(request.NewErrParamMaxLen( - "endpoint host", 255, host, - )) - } - - if paramErrs.Len() > 0 { - return paramErrs - } - return nil -} - -// ValidHostLabel returns if the label is a valid RFC 3986 host label. -func ValidHostLabel(label string) bool { - if l := len(label); l == 0 || l > 63 { - return false - } - for _, r := range label { - switch { - case r >= '0' && r <= '9': - case r >= 'A' && r <= 'Z': - case r >= 'a' && r <= 'z': - case r == '-': - default: - return false - } - } - - return true -} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go deleted file mode 100644 index 915b0fcaf..000000000 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go +++ /dev/null @@ -1,54 +0,0 @@ -package protocol - -import ( - "strings" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/request" -) - -// HostPrefixHandlerName is the handler name for the host prefix request -// handler. -const HostPrefixHandlerName = "awssdk.endpoint.HostPrefixHandler" - -// NewHostPrefixHandler constructs a build handler -func NewHostPrefixHandler(prefix string, labelsFn func() map[string]string) request.NamedHandler { - builder := HostPrefixBuilder{ - Prefix: prefix, - LabelsFn: labelsFn, - } - - return request.NamedHandler{ - Name: HostPrefixHandlerName, - Fn: builder.Build, - } -} - -// HostPrefixBuilder provides the request handler to expand and prepend -// the host prefix into the operation's request endpoint host. -type HostPrefixBuilder struct { - Prefix string - LabelsFn func() map[string]string -} - -// Build updates the passed in Request with the HostPrefix template expanded. -func (h HostPrefixBuilder) Build(r *request.Request) { - if aws.BoolValue(r.Config.DisableEndpointHostPrefix) { - return - } - - var labels map[string]string - if h.LabelsFn != nil { - labels = h.LabelsFn() - } - - prefix := h.Prefix - for name, value := range labels { - prefix = strings.Replace(prefix, "{"+name+"}", value, -1) - } - - r.HTTPRequest.URL.Host = prefix + r.HTTPRequest.URL.Host - if len(r.HTTPRequest.Host) > 0 { - r.HTTPRequest.Host = prefix + r.HTTPRequest.Host - } -} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go deleted file mode 100644 index 864fb6704..000000000 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/build.go +++ /dev/null @@ -1,296 +0,0 @@ -// Package jsonutil provides JSON serialization of AWS requests and responses. -package jsonutil - -import ( - "bytes" - "encoding/base64" - "encoding/json" - "fmt" - "math" - "reflect" - "sort" - "strconv" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/private/protocol" -) - -var timeType = reflect.ValueOf(time.Time{}).Type() -var byteSliceType = reflect.ValueOf([]byte{}).Type() - -// BuildJSON builds a JSON string for a given object v. -func BuildJSON(v interface{}) ([]byte, error) { - var buf bytes.Buffer - - err := buildAny(reflect.ValueOf(v), &buf, "") - return buf.Bytes(), err -} - -func buildAny(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error { - origVal := value - value = reflect.Indirect(value) - if !value.IsValid() { - return nil - } - - vtype := value.Type() - - t := tag.Get("type") - if t == "" { - switch vtype.Kind() { - case reflect.Struct: - // also it can't be a time object - if value.Type() != timeType { - t = "structure" - } - case reflect.Slice: - // also it can't be a byte slice - if _, ok := value.Interface().([]byte); !ok { - t = "list" - } - case reflect.Map: - // cannot be a JSONValue map - if _, ok := value.Interface().(aws.JSONValue); !ok { - t = "map" - } - } - } - - switch t { - case "structure": - if field, ok := vtype.FieldByName("_"); ok { - tag = field.Tag - } - return buildStruct(value, buf, tag) - case "list": - return buildList(value, buf, tag) - case "map": - return buildMap(value, buf, tag) - default: - return buildScalar(origVal, buf, tag) - } -} - -func buildStruct(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error { - if !value.IsValid() { - return nil - } - - // unwrap payloads - if payload := tag.Get("payload"); payload != "" { - field, _ := value.Type().FieldByName(payload) - tag = field.Tag - value = elemOf(value.FieldByName(payload)) - - if !value.IsValid() { - return nil - } - } - - buf.WriteByte('{') - - t := value.Type() - first := true - for i := 0; i < t.NumField(); i++ { - member := value.Field(i) - - // This allocates the most memory. - // Additionally, we cannot skip nil fields due to - // idempotency auto filling. - field := t.Field(i) - - if field.PkgPath != "" { - continue // ignore unexported fields - } - if field.Tag.Get("json") == "-" { - continue - } - if field.Tag.Get("location") != "" { - continue // ignore non-body elements - } - if field.Tag.Get("ignore") != "" { - continue - } - - if protocol.CanSetIdempotencyToken(member, field) { - token := protocol.GetIdempotencyToken() - member = reflect.ValueOf(&token) - } - - if (member.Kind() == reflect.Ptr || member.Kind() == reflect.Slice || member.Kind() == reflect.Map) && member.IsNil() { - continue // ignore unset fields - } - - if first { - first = false - } else { - buf.WriteByte(',') - } - - // figure out what this field is called - name := field.Name - if locName := field.Tag.Get("locationName"); locName != "" { - name = locName - } - - writeString(name, buf) - buf.WriteString(`:`) - - err := buildAny(member, buf, field.Tag) - if err != nil { - return err - } - - } - - buf.WriteString("}") - - return nil -} - -func buildList(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error { - buf.WriteString("[") - - for i := 0; i < value.Len(); i++ { - buildAny(value.Index(i), buf, "") - - if i < value.Len()-1 { - buf.WriteString(",") - } - } - - buf.WriteString("]") - - return nil -} - -type sortedValues []reflect.Value - -func (sv sortedValues) Len() int { return len(sv) } -func (sv sortedValues) Swap(i, j int) { sv[i], sv[j] = sv[j], sv[i] } -func (sv sortedValues) Less(i, j int) bool { return sv[i].String() < sv[j].String() } - -func buildMap(value reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error { - buf.WriteString("{") - - sv := sortedValues(value.MapKeys()) - sort.Sort(sv) - - for i, k := range sv { - if i > 0 { - buf.WriteByte(',') - } - - writeString(k.String(), buf) - buf.WriteString(`:`) - - buildAny(value.MapIndex(k), buf, "") - } - - buf.WriteString("}") - - return nil -} - -func buildScalar(v reflect.Value, buf *bytes.Buffer, tag reflect.StructTag) error { - // prevents allocation on the heap. - scratch := [64]byte{} - switch value := reflect.Indirect(v); value.Kind() { - case reflect.String: - writeString(value.String(), buf) - case reflect.Bool: - if value.Bool() { - buf.WriteString("true") - } else { - buf.WriteString("false") - } - case reflect.Int64: - buf.Write(strconv.AppendInt(scratch[:0], value.Int(), 10)) - case reflect.Float64: - f := value.Float() - if math.IsInf(f, 0) || math.IsNaN(f) { - return &json.UnsupportedValueError{Value: v, Str: strconv.FormatFloat(f, 'f', -1, 64)} - } - buf.Write(strconv.AppendFloat(scratch[:0], f, 'f', -1, 64)) - default: - switch converted := value.Interface().(type) { - case time.Time: - format := tag.Get("timestampFormat") - if len(format) == 0 { - format = protocol.UnixTimeFormatName - } - - ts := protocol.FormatTime(format, converted) - if format != protocol.UnixTimeFormatName { - ts = `"` + ts + `"` - } - - buf.WriteString(ts) - case []byte: - if !value.IsNil() { - buf.WriteByte('"') - if len(converted) < 1024 { - // for small buffers, using Encode directly is much faster. - dst := make([]byte, base64.StdEncoding.EncodedLen(len(converted))) - base64.StdEncoding.Encode(dst, converted) - buf.Write(dst) - } else { - // for large buffers, avoid unnecessary extra temporary - // buffer space. - enc := base64.NewEncoder(base64.StdEncoding, buf) - enc.Write(converted) - enc.Close() - } - buf.WriteByte('"') - } - case aws.JSONValue: - str, err := protocol.EncodeJSONValue(converted, protocol.QuotedEscape) - if err != nil { - return fmt.Errorf("unable to encode JSONValue, %v", err) - } - buf.WriteString(str) - default: - return fmt.Errorf("unsupported JSON value %v (%s)", value.Interface(), value.Type()) - } - } - return nil -} - -var hex = "0123456789abcdef" - -func writeString(s string, buf *bytes.Buffer) { - buf.WriteByte('"') - for i := 0; i < len(s); i++ { - if s[i] == '"' { - buf.WriteString(`\"`) - } else if s[i] == '\\' { - buf.WriteString(`\\`) - } else if s[i] == '\b' { - buf.WriteString(`\b`) - } else if s[i] == '\f' { - buf.WriteString(`\f`) - } else if s[i] == '\r' { - buf.WriteString(`\r`) - } else if s[i] == '\t' { - buf.WriteString(`\t`) - } else if s[i] == '\n' { - buf.WriteString(`\n`) - } else if s[i] < 32 { - buf.WriteString("\\u00") - buf.WriteByte(hex[s[i]>>4]) - buf.WriteByte(hex[s[i]&0xF]) - } else { - buf.WriteByte(s[i]) - } - } - buf.WriteByte('"') -} - -// Returns the reflection element of a value, if it is a pointer. -func elemOf(value reflect.Value) reflect.Value { - for value.Kind() == reflect.Ptr { - value = value.Elem() - } - return value -} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go deleted file mode 100644 index ea0da79a5..000000000 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go +++ /dev/null @@ -1,250 +0,0 @@ -package jsonutil - -import ( - "bytes" - "encoding/base64" - "encoding/json" - "fmt" - "io" - "reflect" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/private/protocol" -) - -// UnmarshalJSONError unmarshal's the reader's JSON document into the passed in -// type. The value to unmarshal the json document into must be a pointer to the -// type. -func UnmarshalJSONError(v interface{}, stream io.Reader) error { - var errBuf bytes.Buffer - body := io.TeeReader(stream, &errBuf) - - err := json.NewDecoder(body).Decode(v) - if err != nil { - msg := "failed decoding error message" - if err == io.EOF { - msg = "error message missing" - err = nil - } - return awserr.NewUnmarshalError(err, msg, errBuf.Bytes()) - } - - return nil -} - -// UnmarshalJSON reads a stream and unmarshals the results in object v. -func UnmarshalJSON(v interface{}, stream io.Reader) error { - var out interface{} - - err := json.NewDecoder(stream).Decode(&out) - if err == io.EOF { - return nil - } else if err != nil { - return err - } - - return unmarshalAny(reflect.ValueOf(v), out, "") -} - -func unmarshalAny(value reflect.Value, data interface{}, tag reflect.StructTag) error { - vtype := value.Type() - if vtype.Kind() == reflect.Ptr { - vtype = vtype.Elem() // check kind of actual element type - } - - t := tag.Get("type") - if t == "" { - switch vtype.Kind() { - case reflect.Struct: - // also it can't be a time object - if _, ok := value.Interface().(*time.Time); !ok { - t = "structure" - } - case reflect.Slice: - // also it can't be a byte slice - if _, ok := value.Interface().([]byte); !ok { - t = "list" - } - case reflect.Map: - // cannot be a JSONValue map - if _, ok := value.Interface().(aws.JSONValue); !ok { - t = "map" - } - } - } - - switch t { - case "structure": - if field, ok := vtype.FieldByName("_"); ok { - tag = field.Tag - } - return unmarshalStruct(value, data, tag) - case "list": - return unmarshalList(value, data, tag) - case "map": - return unmarshalMap(value, data, tag) - default: - return unmarshalScalar(value, data, tag) - } -} - -func unmarshalStruct(value reflect.Value, data interface{}, tag reflect.StructTag) error { - if data == nil { - return nil - } - mapData, ok := data.(map[string]interface{}) - if !ok { - return fmt.Errorf("JSON value is not a structure (%#v)", data) - } - - t := value.Type() - if value.Kind() == reflect.Ptr { - if value.IsNil() { // create the structure if it's nil - s := reflect.New(value.Type().Elem()) - value.Set(s) - value = s - } - - value = value.Elem() - t = t.Elem() - } - - // unwrap any payloads - if payload := tag.Get("payload"); payload != "" { - field, _ := t.FieldByName(payload) - return unmarshalAny(value.FieldByName(payload), data, field.Tag) - } - - for i := 0; i < t.NumField(); i++ { - field := t.Field(i) - if field.PkgPath != "" { - continue // ignore unexported fields - } - - // figure out what this field is called - name := field.Name - if locName := field.Tag.Get("locationName"); locName != "" { - name = locName - } - - member := value.FieldByIndex(field.Index) - err := unmarshalAny(member, mapData[name], field.Tag) - if err != nil { - return err - } - } - return nil -} - -func unmarshalList(value reflect.Value, data interface{}, tag reflect.StructTag) error { - if data == nil { - return nil - } - listData, ok := data.([]interface{}) - if !ok { - return fmt.Errorf("JSON value is not a list (%#v)", data) - } - - if value.IsNil() { - l := len(listData) - value.Set(reflect.MakeSlice(value.Type(), l, l)) - } - - for i, c := range listData { - err := unmarshalAny(value.Index(i), c, "") - if err != nil { - return err - } - } - - return nil -} - -func unmarshalMap(value reflect.Value, data interface{}, tag reflect.StructTag) error { - if data == nil { - return nil - } - mapData, ok := data.(map[string]interface{}) - if !ok { - return fmt.Errorf("JSON value is not a map (%#v)", data) - } - - if value.IsNil() { - value.Set(reflect.MakeMap(value.Type())) - } - - for k, v := range mapData { - kvalue := reflect.ValueOf(k) - vvalue := reflect.New(value.Type().Elem()).Elem() - - unmarshalAny(vvalue, v, "") - value.SetMapIndex(kvalue, vvalue) - } - - return nil -} - -func unmarshalScalar(value reflect.Value, data interface{}, tag reflect.StructTag) error { - - switch d := data.(type) { - case nil: - return nil // nothing to do here - case string: - switch value.Interface().(type) { - case *string: - value.Set(reflect.ValueOf(&d)) - case []byte: - b, err := base64.StdEncoding.DecodeString(d) - if err != nil { - return err - } - value.Set(reflect.ValueOf(b)) - case *time.Time: - format := tag.Get("timestampFormat") - if len(format) == 0 { - format = protocol.ISO8601TimeFormatName - } - - t, err := protocol.ParseTime(format, d) - if err != nil { - return err - } - value.Set(reflect.ValueOf(&t)) - case aws.JSONValue: - // No need to use escaping as the value is a non-quoted string. - v, err := protocol.DecodeJSONValue(d, protocol.NoEscape) - if err != nil { - return err - } - value.Set(reflect.ValueOf(v)) - default: - return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type()) - } - case float64: - switch value.Interface().(type) { - case *int64: - di := int64(d) - value.Set(reflect.ValueOf(&di)) - case *float64: - value.Set(reflect.ValueOf(&d)) - case *time.Time: - // Time unmarshaled from a float64 can only be epoch seconds - t := time.Unix(int64(d), 0).UTC() - value.Set(reflect.ValueOf(&t)) - default: - return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type()) - } - case bool: - switch value.Interface().(type) { - case *bool: - value.Set(reflect.ValueOf(&d)) - default: - return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type()) - } - default: - return fmt.Errorf("unsupported JSON value (%v)", data) - } - return nil -} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go deleted file mode 100644 index bfedc9fd4..000000000 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/jsonrpc/jsonrpc.go +++ /dev/null @@ -1,110 +0,0 @@ -// Package jsonrpc provides JSON RPC utilities for serialization of AWS -// requests and responses. -package jsonrpc - -//go:generate go run -tags codegen ../../../models/protocol_tests/generate.go ../../../models/protocol_tests/input/json.json build_test.go -//go:generate go run -tags codegen ../../../models/protocol_tests/generate.go ../../../models/protocol_tests/output/json.json unmarshal_test.go - -import ( - "strings" - - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/private/protocol/json/jsonutil" - "github.com/aws/aws-sdk-go/private/protocol/rest" -) - -var emptyJSON = []byte("{}") - -// BuildHandler is a named request handler for building jsonrpc protocol requests -var BuildHandler = request.NamedHandler{Name: "awssdk.jsonrpc.Build", Fn: Build} - -// UnmarshalHandler is a named request handler for unmarshaling jsonrpc protocol requests -var UnmarshalHandler = request.NamedHandler{Name: "awssdk.jsonrpc.Unmarshal", Fn: Unmarshal} - -// UnmarshalMetaHandler is a named request handler for unmarshaling jsonrpc protocol request metadata -var UnmarshalMetaHandler = request.NamedHandler{Name: "awssdk.jsonrpc.UnmarshalMeta", Fn: UnmarshalMeta} - -// UnmarshalErrorHandler is a named request handler for unmarshaling jsonrpc protocol request errors -var UnmarshalErrorHandler = request.NamedHandler{Name: "awssdk.jsonrpc.UnmarshalError", Fn: UnmarshalError} - -// Build builds a JSON payload for a JSON RPC request. -func Build(req *request.Request) { - var buf []byte - var err error - if req.ParamsFilled() { - buf, err = jsonutil.BuildJSON(req.Params) - if err != nil { - req.Error = awserr.New(request.ErrCodeSerialization, "failed encoding JSON RPC request", err) - return - } - } else { - buf = emptyJSON - } - - if req.ClientInfo.TargetPrefix != "" || string(buf) != "{}" { - req.SetBufferBody(buf) - } - - if req.ClientInfo.TargetPrefix != "" { - target := req.ClientInfo.TargetPrefix + "." + req.Operation.Name - req.HTTPRequest.Header.Add("X-Amz-Target", target) - } - - // Only set the content type if one is not already specified and an - // JSONVersion is specified. - if ct, v := req.HTTPRequest.Header.Get("Content-Type"), req.ClientInfo.JSONVersion; len(ct) == 0 && len(v) != 0 { - jsonVersion := req.ClientInfo.JSONVersion - req.HTTPRequest.Header.Set("Content-Type", "application/x-amz-json-"+jsonVersion) - } -} - -// Unmarshal unmarshals a response for a JSON RPC service. -func Unmarshal(req *request.Request) { - defer req.HTTPResponse.Body.Close() - if req.DataFilled() { - err := jsonutil.UnmarshalJSON(req.Data, req.HTTPResponse.Body) - if err != nil { - req.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, "failed decoding JSON RPC response", err), - req.HTTPResponse.StatusCode, - req.RequestID, - ) - } - } - return -} - -// UnmarshalMeta unmarshals headers from a response for a JSON RPC service. -func UnmarshalMeta(req *request.Request) { - rest.UnmarshalMeta(req) -} - -// UnmarshalError unmarshals an error response for a JSON RPC service. -func UnmarshalError(req *request.Request) { - defer req.HTTPResponse.Body.Close() - - var jsonErr jsonErrorResponse - err := jsonutil.UnmarshalJSONError(&jsonErr, req.HTTPResponse.Body) - if err != nil { - req.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, - "failed to unmarshal error message", err), - req.HTTPResponse.StatusCode, - req.RequestID, - ) - return - } - - codes := strings.SplitN(jsonErr.Code, "#", 2) - req.Error = awserr.NewRequestFailure( - awserr.New(codes[len(codes)-1], jsonErr.Message, nil), - req.HTTPResponse.StatusCode, - req.RequestID, - ) -} - -type jsonErrorResponse struct { - Code string `json:"__type"` - Message string `json:"message"` -} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go index 0cb99eb57..60e5b09d5 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go @@ -21,7 +21,7 @@ func Build(r *request.Request) { "Version": {r.ClientInfo.APIVersion}, } if err := queryutil.Parse(body, r.Params, false); err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "failed encoding Query request", err) + r.Error = awserr.New("SerializationError", "failed encoding Query request", err) return } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go index f69c1efc9..e0f4d5a54 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal.go @@ -23,11 +23,7 @@ func Unmarshal(r *request.Request) { decoder := xml.NewDecoder(r.HTTPResponse.Body) err := xmlutil.UnmarshalXML(r.Data, decoder, r.Operation.Name+"Result") if err != nil { - r.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, "failed decoding Query response", err), - r.HTTPResponse.StatusCode, - r.RequestID, - ) + r.Error = awserr.New("SerializationError", "failed decoding Query response", err) return } } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go index 831b0110c..f21429617 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/unmarshal_error.go @@ -2,68 +2,65 @@ package query import ( "encoding/xml" - "fmt" + "io/ioutil" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil" ) +type xmlErrorResponse struct { + XMLName xml.Name `xml:"ErrorResponse"` + Code string `xml:"Error>Code"` + Message string `xml:"Error>Message"` + RequestID string `xml:"RequestId"` +} + +type xmlServiceUnavailableResponse struct { + XMLName xml.Name `xml:"ServiceUnavailableException"` +} + // UnmarshalErrorHandler is a name request handler to unmarshal request errors var UnmarshalErrorHandler = request.NamedHandler{Name: "awssdk.query.UnmarshalError", Fn: UnmarshalError} -type xmlErrorResponse struct { - Code string `xml:"Error>Code"` - Message string `xml:"Error>Message"` - RequestID string `xml:"RequestId"` -} - -type xmlResponseError struct { - xmlErrorResponse -} - -func (e *xmlResponseError) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error { - const svcUnavailableTagName = "ServiceUnavailableException" - const errorResponseTagName = "ErrorResponse" - - switch start.Name.Local { - case svcUnavailableTagName: - e.Code = svcUnavailableTagName - e.Message = "service is unavailable" - return d.Skip() - - case errorResponseTagName: - return d.DecodeElement(&e.xmlErrorResponse, &start) - - default: - return fmt.Errorf("unknown error response tag, %v", start) - } -} - // UnmarshalError unmarshals an error response for an AWS Query service. func UnmarshalError(r *request.Request) { defer r.HTTPResponse.Body.Close() - var respErr xmlResponseError - err := xmlutil.UnmarshalXMLError(&respErr, r.HTTPResponse.Body) + bodyBytes, err := ioutil.ReadAll(r.HTTPResponse.Body) if err != nil { + r.Error = awserr.New("SerializationError", "failed to read from query HTTP response body", err) + return + } + + // First check for specific error + resp := xmlErrorResponse{} + decodeErr := xml.Unmarshal(bodyBytes, &resp) + if decodeErr == nil { + reqID := resp.RequestID + if reqID == "" { + reqID = r.RequestID + } r.Error = awserr.NewRequestFailure( - awserr.New(request.ErrCodeSerialization, - "failed to unmarshal error message", err), + awserr.New(resp.Code, resp.Message, nil), + r.HTTPResponse.StatusCode, + reqID, + ) + return + } + + // Check for unhandled error + servUnavailResp := xmlServiceUnavailableResponse{} + unavailErr := xml.Unmarshal(bodyBytes, &servUnavailResp) + if unavailErr == nil { + r.Error = awserr.NewRequestFailure( + awserr.New("ServiceUnavailableException", "service is unavailable", nil), r.HTTPResponse.StatusCode, r.RequestID, ) return } - reqID := respErr.RequestID - if len(reqID) == 0 { - reqID = r.RequestID - } - - r.Error = awserr.NewRequestFailure( - awserr.New(respErr.Code, respErr.Message, nil), - r.HTTPResponse.StatusCode, - reqID, - ) + // Failed to retrieve any error message from the response body + r.Error = awserr.New("SerializationError", + "failed to decode query XML error response", decodeErr) } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go index 1301b149d..b34f5258a 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/build.go @@ -25,8 +25,6 @@ var noEscape [256]bool var errValueNotSet = fmt.Errorf("value not set") -var byteSliceType = reflect.TypeOf([]byte{}) - func init() { for i := 0; i < len(noEscape); i++ { // AWS expects every character except these to be escaped @@ -96,14 +94,6 @@ func buildLocationElements(r *request.Request, v reflect.Value, buildGETQuery bo continue } - // Support the ability to customize values to be marshaled as a - // blob even though they were modeled as a string. Required for S3 - // API operations like SSECustomerKey is modeled as stirng but - // required to be base64 encoded in request. - if field.Tag.Get("marshal-as") == "blob" { - m = m.Convert(byteSliceType) - } - var err error switch field.Tag.Get("location") { case "headers": // header maps @@ -147,7 +137,7 @@ func buildBody(r *request.Request, v reflect.Value) { case string: r.SetStringBody(reader) default: - r.Error = awserr.New(request.ErrCodeSerialization, + r.Error = awserr.New("SerializationError", "failed to encode REST request", fmt.Errorf("unknown payload type %s", payload.Type())) } @@ -162,12 +152,9 @@ func buildHeader(header *http.Header, v reflect.Value, name string, tag reflect. if err == errValueNotSet { return nil } else if err != nil { - return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err) + return awserr.New("SerializationError", "failed to encode REST request", err) } - name = strings.TrimSpace(name) - str = strings.TrimSpace(str) - header.Add(name, str) return nil @@ -180,13 +167,11 @@ func buildHeaderMap(header *http.Header, v reflect.Value, tag reflect.StructTag) if err == errValueNotSet { continue } else if err != nil { - return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err) + return awserr.New("SerializationError", "failed to encode REST request", err) } - keyStr := strings.TrimSpace(key.String()) - str = strings.TrimSpace(str) - header.Add(prefix+keyStr, str) + header.Add(prefix+key.String(), str) } return nil } @@ -196,7 +181,7 @@ func buildURI(u *url.URL, v reflect.Value, name string, tag reflect.StructTag) e if err == errValueNotSet { return nil } else if err != nil { - return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err) + return awserr.New("SerializationError", "failed to encode REST request", err) } u.Path = strings.Replace(u.Path, "{"+name+"}", value, -1) @@ -229,7 +214,7 @@ func buildQueryString(query url.Values, v reflect.Value, name string, tag reflec if err == errValueNotSet { return nil } else if err != nil { - return awserr.New(request.ErrCodeSerialization, "failed to encode REST request", err) + return awserr.New("SerializationError", "failed to encode REST request", err) } query.Set(name, str) } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go index de021367d..33fd53b12 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/rest/unmarshal.go @@ -57,7 +57,7 @@ func unmarshalBody(r *request.Request, v reflect.Value) { defer r.HTTPResponse.Body.Close() b, err := ioutil.ReadAll(r.HTTPResponse.Body) if err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err) + r.Error = awserr.New("SerializationError", "failed to decode REST response", err) } else { payload.Set(reflect.ValueOf(b)) } @@ -65,7 +65,7 @@ func unmarshalBody(r *request.Request, v reflect.Value) { defer r.HTTPResponse.Body.Close() b, err := ioutil.ReadAll(r.HTTPResponse.Body) if err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err) + r.Error = awserr.New("SerializationError", "failed to decode REST response", err) } else { str := string(b) payload.Set(reflect.ValueOf(&str)) @@ -77,7 +77,7 @@ func unmarshalBody(r *request.Request, v reflect.Value) { case "io.ReadSeeker": b, err := ioutil.ReadAll(r.HTTPResponse.Body) if err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, + r.Error = awserr.New("SerializationError", "failed to read response body", err) return } @@ -85,7 +85,7 @@ func unmarshalBody(r *request.Request, v reflect.Value) { default: io.Copy(ioutil.Discard, r.HTTPResponse.Body) defer r.HTTPResponse.Body.Close() - r.Error = awserr.New(request.ErrCodeSerialization, + r.Error = awserr.New("SerializationError", "failed to decode REST response", fmt.Errorf("unknown payload type %s", payload.Type())) } @@ -115,14 +115,14 @@ func unmarshalLocationElements(r *request.Request, v reflect.Value) { case "header": err := unmarshalHeader(m, r.HTTPResponse.Header.Get(name), field.Tag) if err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err) + r.Error = awserr.New("SerializationError", "failed to decode REST response", err) break } case "headers": prefix := field.Tag.Get("locationName") err := unmarshalHeaderMap(m, r.HTTPResponse.Header, prefix) if err != nil { - r.Error = awserr.New(request.ErrCodeSerialization, "failed to decode REST response", err) + r.Error = awserr.New("SerializationError", "failed to decode REST response", err) break } } diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go index cf981fe95..1bfe45f65 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go @@ -87,7 +87,7 @@ func (b *xmlBuilder) buildValue(value reflect.Value, current *XMLNode, tag refle } } -// buildStruct adds a struct and its fields to the current XMLNode. All fields and any nested +// buildStruct adds a struct and its fields to the current XMLNode. All fields any any nested // types are converted to XMLNodes also. func (b *xmlBuilder) buildStruct(value reflect.Value, current *XMLNode, tag reflect.StructTag) error { if !value.IsValid() { diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go index 7108d3800..ff1ef6830 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/unmarshal.go @@ -1,7 +1,6 @@ package xmlutil import ( - "bytes" "encoding/base64" "encoding/xml" "fmt" @@ -11,27 +10,9 @@ import ( "strings" "time" - "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/private/protocol" ) -// UnmarshalXMLError unmarshals the XML error from the stream into the value -// type specified. The value must be a pointer. If the message fails to -// unmarshal, the message content will be included in the returned error as a -// awserr.UnmarshalError. -func UnmarshalXMLError(v interface{}, stream io.Reader) error { - var errBuf bytes.Buffer - body := io.TeeReader(stream, &errBuf) - - err := xml.NewDecoder(body).Decode(v) - if err != nil && err != io.EOF { - return awserr.NewUnmarshalError(err, - "failed to unmarshal error message", errBuf.Bytes()) - } - - return nil -} - // UnmarshalXML deserializes an xml.Decoder into the container v. V // needs to match the shape of the XML expected to be decoded. // If the shape doesn't match unmarshaling will fail. diff --git a/vendor/github.com/aws/aws-sdk-go/service/acmpca/api.go b/vendor/github.com/aws/aws-sdk-go/service/acmpca/api.go deleted file mode 100644 index b9f53ae7a..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/acmpca/api.go +++ /dev/null @@ -1,4999 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -package acmpca - -import ( - "fmt" - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awsutil" - "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/private/protocol" - "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" -) - -const opCreateCertificateAuthority = "CreateCertificateAuthority" - -// CreateCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the CreateCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateCertificateAuthority for more information on using the CreateCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateCertificateAuthorityRequest method. -// req, resp := client.CreateCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreateCertificateAuthority -func (c *ACMPCA) CreateCertificateAuthorityRequest(input *CreateCertificateAuthorityInput) (req *request.Request, output *CreateCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opCreateCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateCertificateAuthorityInput{} - } - - output = &CreateCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Creates a root or subordinate private certificate authority (CA). You must -// specify the CA configuration, the certificate revocation list (CRL) configuration, -// the CA type, and an optional idempotency token to avoid accidental creation -// of multiple CAs. The CA configuration specifies the name of the algorithm -// and key size to be used to create the CA private key, the type of signing -// algorithm that the CA uses, and X.500 subject information. The CRL configuration -// specifies the CRL expiration period in days (the validity period of the CRL), -// the Amazon S3 bucket that will contain the CRL, and a CNAME alias for the -// S3 bucket that is included in certificates issued by the CA. If successful, -// this action returns the Amazon Resource Name (ARN) of the CA. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation CreateCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeInvalidArgsException "InvalidArgsException" -// One or more of the specified arguments was not valid. -// -// * ErrCodeInvalidPolicyException "InvalidPolicyException" -// The S3 bucket policy is not valid. The policy must give ACM Private CA rights -// to read from and write to the bucket and find the bucket location. -// -// * ErrCodeInvalidTagException "InvalidTagException" -// The tag associated with the CA is not valid. The invalid argument is contained -// in the message field. -// -// * ErrCodeLimitExceededException "LimitExceededException" -// An ACM Private CA limit has been exceeded. See the exception message returned -// to determine the limit that was exceeded. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreateCertificateAuthority -func (c *ACMPCA) CreateCertificateAuthority(input *CreateCertificateAuthorityInput) (*CreateCertificateAuthorityOutput, error) { - req, out := c.CreateCertificateAuthorityRequest(input) - return out, req.Send() -} - -// CreateCertificateAuthorityWithContext is the same as CreateCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See CreateCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) CreateCertificateAuthorityWithContext(ctx aws.Context, input *CreateCertificateAuthorityInput, opts ...request.Option) (*CreateCertificateAuthorityOutput, error) { - req, out := c.CreateCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateCertificateAuthorityAuditReport = "CreateCertificateAuthorityAuditReport" - -// CreateCertificateAuthorityAuditReportRequest generates a "aws/request.Request" representing the -// client's request for the CreateCertificateAuthorityAuditReport operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateCertificateAuthorityAuditReport for more information on using the CreateCertificateAuthorityAuditReport -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateCertificateAuthorityAuditReportRequest method. -// req, resp := client.CreateCertificateAuthorityAuditReportRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreateCertificateAuthorityAuditReport -func (c *ACMPCA) CreateCertificateAuthorityAuditReportRequest(input *CreateCertificateAuthorityAuditReportInput) (req *request.Request, output *CreateCertificateAuthorityAuditReportOutput) { - op := &request.Operation{ - Name: opCreateCertificateAuthorityAuditReport, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateCertificateAuthorityAuditReportInput{} - } - - output = &CreateCertificateAuthorityAuditReportOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateCertificateAuthorityAuditReport API operation for AWS Certificate Manager Private Certificate Authority. -// -// Creates an audit report that lists every time that your CA private key is -// used. The report is saved in the Amazon S3 bucket that you specify on input. -// The IssueCertificate and RevokeCertificate actions use the private key. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation CreateCertificateAuthorityAuditReport for usage and error information. -// -// Returned Error Codes: -// * ErrCodeRequestInProgressException "RequestInProgressException" -// Your request is already in progress. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidArgsException "InvalidArgsException" -// One or more of the specified arguments was not valid. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreateCertificateAuthorityAuditReport -func (c *ACMPCA) CreateCertificateAuthorityAuditReport(input *CreateCertificateAuthorityAuditReportInput) (*CreateCertificateAuthorityAuditReportOutput, error) { - req, out := c.CreateCertificateAuthorityAuditReportRequest(input) - return out, req.Send() -} - -// CreateCertificateAuthorityAuditReportWithContext is the same as CreateCertificateAuthorityAuditReport with the addition of -// the ability to pass a context and additional request options. -// -// See CreateCertificateAuthorityAuditReport for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) CreateCertificateAuthorityAuditReportWithContext(ctx aws.Context, input *CreateCertificateAuthorityAuditReportInput, opts ...request.Option) (*CreateCertificateAuthorityAuditReportOutput, error) { - req, out := c.CreateCertificateAuthorityAuditReportRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreatePermission = "CreatePermission" - -// CreatePermissionRequest generates a "aws/request.Request" representing the -// client's request for the CreatePermission operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreatePermission for more information on using the CreatePermission -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreatePermissionRequest method. -// req, resp := client.CreatePermissionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreatePermission -func (c *ACMPCA) CreatePermissionRequest(input *CreatePermissionInput) (req *request.Request, output *CreatePermissionOutput) { - op := &request.Operation{ - Name: opCreatePermission, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreatePermissionInput{} - } - - output = &CreatePermissionOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// CreatePermission API operation for AWS Certificate Manager Private Certificate Authority. -// -// Assigns permissions from a private CA to a designated AWS service. Services -// are specified by their service principals and can be given permission to -// create and retrieve certificates on a private CA. Services can also be given -// permission to list the active permissions that the private CA has granted. -// For ACM to automatically renew your private CA's certificates, you must assign -// all possible permissions from the CA to the ACM service principal. -// -// At this time, you can only assign permissions to ACM (acm.amazonaws.com). -// Permissions can be revoked with the DeletePermission action and listed with -// the ListPermissions action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation CreatePermission for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodePermissionAlreadyExistsException "PermissionAlreadyExistsException" -// The designated permission has already been given to the user. -// -// * ErrCodeLimitExceededException "LimitExceededException" -// An ACM Private CA limit has been exceeded. See the exception message returned -// to determine the limit that was exceeded. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/CreatePermission -func (c *ACMPCA) CreatePermission(input *CreatePermissionInput) (*CreatePermissionOutput, error) { - req, out := c.CreatePermissionRequest(input) - return out, req.Send() -} - -// CreatePermissionWithContext is the same as CreatePermission with the addition of -// the ability to pass a context and additional request options. -// -// See CreatePermission for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) CreatePermissionWithContext(ctx aws.Context, input *CreatePermissionInput, opts ...request.Option) (*CreatePermissionOutput, error) { - req, out := c.CreatePermissionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteCertificateAuthority = "DeleteCertificateAuthority" - -// DeleteCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the DeleteCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteCertificateAuthority for more information on using the DeleteCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteCertificateAuthorityRequest method. -// req, resp := client.DeleteCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DeleteCertificateAuthority -func (c *ACMPCA) DeleteCertificateAuthorityRequest(input *DeleteCertificateAuthorityInput) (req *request.Request, output *DeleteCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opDeleteCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteCertificateAuthorityInput{} - } - - output = &DeleteCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// DeleteCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Deletes a private certificate authority (CA). You must provide the Amazon -// Resource Name (ARN) of the private CA that you want to delete. You can find -// the ARN by calling the ListCertificateAuthorities action. -// -// Deleting a CA will invalidate other CAs and certificates below it in your -// CA hierarchy. -// -// Before you can delete a CA that you have created and activated, you must -// disable it. To do this, call the UpdateCertificateAuthority action and set -// the CertificateAuthorityStatus parameter to DISABLED. -// -// Additionally, you can delete a CA if you are waiting for it to be created -// (that is, the status of the CA is CREATING). You can also delete it if the -// CA has been created but you haven't yet imported the signed certificate into -// ACM Private CA (that is, the status of the CA is PENDING_CERTIFICATE). -// -// When you successfully call DeleteCertificateAuthority, the CA's status changes -// to DELETED. However, the CA won't be permanently deleted until the restoration -// period has passed. By default, if you do not set the PermanentDeletionTimeInDays -// parameter, the CA remains restorable for 30 days. You can set the parameter -// from 7 to 30 days. The DescribeCertificateAuthority action returns the time -// remaining in the restoration window of a private CA in the DELETED state. -// To restore an eligible CA, call the RestoreCertificateAuthority action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation DeleteCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeConcurrentModificationException "ConcurrentModificationException" -// A previous update to your private CA is still ongoing. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DeleteCertificateAuthority -func (c *ACMPCA) DeleteCertificateAuthority(input *DeleteCertificateAuthorityInput) (*DeleteCertificateAuthorityOutput, error) { - req, out := c.DeleteCertificateAuthorityRequest(input) - return out, req.Send() -} - -// DeleteCertificateAuthorityWithContext is the same as DeleteCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) DeleteCertificateAuthorityWithContext(ctx aws.Context, input *DeleteCertificateAuthorityInput, opts ...request.Option) (*DeleteCertificateAuthorityOutput, error) { - req, out := c.DeleteCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeletePermission = "DeletePermission" - -// DeletePermissionRequest generates a "aws/request.Request" representing the -// client's request for the DeletePermission operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeletePermission for more information on using the DeletePermission -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeletePermissionRequest method. -// req, resp := client.DeletePermissionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DeletePermission -func (c *ACMPCA) DeletePermissionRequest(input *DeletePermissionInput) (req *request.Request, output *DeletePermissionOutput) { - op := &request.Operation{ - Name: opDeletePermission, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeletePermissionInput{} - } - - output = &DeletePermissionOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// DeletePermission API operation for AWS Certificate Manager Private Certificate Authority. -// -// Revokes permissions that a private CA assigned to a designated AWS service. -// Permissions can be created with the CreatePermission action and listed with -// the ListPermissions action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation DeletePermission for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DeletePermission -func (c *ACMPCA) DeletePermission(input *DeletePermissionInput) (*DeletePermissionOutput, error) { - req, out := c.DeletePermissionRequest(input) - return out, req.Send() -} - -// DeletePermissionWithContext is the same as DeletePermission with the addition of -// the ability to pass a context and additional request options. -// -// See DeletePermission for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) DeletePermissionWithContext(ctx aws.Context, input *DeletePermissionInput, opts ...request.Option) (*DeletePermissionOutput, error) { - req, out := c.DeletePermissionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDescribeCertificateAuthority = "DescribeCertificateAuthority" - -// DescribeCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the DescribeCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeCertificateAuthority for more information on using the DescribeCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeCertificateAuthorityRequest method. -// req, resp := client.DescribeCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DescribeCertificateAuthority -func (c *ACMPCA) DescribeCertificateAuthorityRequest(input *DescribeCertificateAuthorityInput) (req *request.Request, output *DescribeCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opDescribeCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DescribeCertificateAuthorityInput{} - } - - output = &DescribeCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Lists information about your private certificate authority (CA). You specify -// the private CA on input by its ARN (Amazon Resource Name). The output contains -// the status of your CA. This can be any of the following: -// -// * CREATING - ACM Private CA is creating your private certificate authority. -// -// * PENDING_CERTIFICATE - The certificate is pending. You must use your -// ACM Private CA-hosted or on-premises root or subordinate CA to sign your -// private CA CSR and then import it into PCA. -// -// * ACTIVE - Your private CA is active. -// -// * DISABLED - Your private CA has been disabled. -// -// * EXPIRED - Your private CA certificate has expired. -// -// * FAILED - Your private CA has failed. Your CA can fail because of problems -// such a network outage or backend AWS failure or other errors. A failed -// CA can never return to the pending state. You must create a new CA. -// -// * DELETED - Your private CA is within the restoration period, after which -// it is permanently deleted. The length of time remaining in the CA's restoration -// period is also included in this action's output. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation DescribeCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DescribeCertificateAuthority -func (c *ACMPCA) DescribeCertificateAuthority(input *DescribeCertificateAuthorityInput) (*DescribeCertificateAuthorityOutput, error) { - req, out := c.DescribeCertificateAuthorityRequest(input) - return out, req.Send() -} - -// DescribeCertificateAuthorityWithContext is the same as DescribeCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) DescribeCertificateAuthorityWithContext(ctx aws.Context, input *DescribeCertificateAuthorityInput, opts ...request.Option) (*DescribeCertificateAuthorityOutput, error) { - req, out := c.DescribeCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDescribeCertificateAuthorityAuditReport = "DescribeCertificateAuthorityAuditReport" - -// DescribeCertificateAuthorityAuditReportRequest generates a "aws/request.Request" representing the -// client's request for the DescribeCertificateAuthorityAuditReport operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeCertificateAuthorityAuditReport for more information on using the DescribeCertificateAuthorityAuditReport -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeCertificateAuthorityAuditReportRequest method. -// req, resp := client.DescribeCertificateAuthorityAuditReportRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DescribeCertificateAuthorityAuditReport -func (c *ACMPCA) DescribeCertificateAuthorityAuditReportRequest(input *DescribeCertificateAuthorityAuditReportInput) (req *request.Request, output *DescribeCertificateAuthorityAuditReportOutput) { - op := &request.Operation{ - Name: opDescribeCertificateAuthorityAuditReport, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DescribeCertificateAuthorityAuditReportInput{} - } - - output = &DescribeCertificateAuthorityAuditReportOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeCertificateAuthorityAuditReport API operation for AWS Certificate Manager Private Certificate Authority. -// -// Lists information about a specific audit report created by calling the CreateCertificateAuthorityAuditReport -// action. Audit information is created every time the certificate authority -// (CA) private key is used. The private key is used when you call the IssueCertificate -// action or the RevokeCertificate action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation DescribeCertificateAuthorityAuditReport for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidArgsException "InvalidArgsException" -// One or more of the specified arguments was not valid. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/DescribeCertificateAuthorityAuditReport -func (c *ACMPCA) DescribeCertificateAuthorityAuditReport(input *DescribeCertificateAuthorityAuditReportInput) (*DescribeCertificateAuthorityAuditReportOutput, error) { - req, out := c.DescribeCertificateAuthorityAuditReportRequest(input) - return out, req.Send() -} - -// DescribeCertificateAuthorityAuditReportWithContext is the same as DescribeCertificateAuthorityAuditReport with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeCertificateAuthorityAuditReport for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) DescribeCertificateAuthorityAuditReportWithContext(ctx aws.Context, input *DescribeCertificateAuthorityAuditReportInput, opts ...request.Option) (*DescribeCertificateAuthorityAuditReportOutput, error) { - req, out := c.DescribeCertificateAuthorityAuditReportRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opGetCertificate = "GetCertificate" - -// GetCertificateRequest generates a "aws/request.Request" representing the -// client's request for the GetCertificate operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetCertificate for more information on using the GetCertificate -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetCertificateRequest method. -// req, resp := client.GetCertificateRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificate -func (c *ACMPCA) GetCertificateRequest(input *GetCertificateInput) (req *request.Request, output *GetCertificateOutput) { - op := &request.Operation{ - Name: opGetCertificate, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &GetCertificateInput{} - } - - output = &GetCertificateOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetCertificate API operation for AWS Certificate Manager Private Certificate Authority. -// -// Retrieves a certificate from your private CA. The ARN of the certificate -// is returned when you call the IssueCertificate action. You must specify both -// the ARN of your private CA and the ARN of the issued certificate when calling -// the GetCertificate action. You can retrieve the certificate if it is in the -// ISSUED state. You can call the CreateCertificateAuthorityAuditReport action -// to create a report that contains information about all of the certificates -// issued and revoked by your private CA. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation GetCertificate for usage and error information. -// -// Returned Error Codes: -// * ErrCodeRequestInProgressException "RequestInProgressException" -// Your request is already in progress. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificate -func (c *ACMPCA) GetCertificate(input *GetCertificateInput) (*GetCertificateOutput, error) { - req, out := c.GetCertificateRequest(input) - return out, req.Send() -} - -// GetCertificateWithContext is the same as GetCertificate with the addition of -// the ability to pass a context and additional request options. -// -// See GetCertificate for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) GetCertificateWithContext(ctx aws.Context, input *GetCertificateInput, opts ...request.Option) (*GetCertificateOutput, error) { - req, out := c.GetCertificateRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opGetCertificateAuthorityCertificate = "GetCertificateAuthorityCertificate" - -// GetCertificateAuthorityCertificateRequest generates a "aws/request.Request" representing the -// client's request for the GetCertificateAuthorityCertificate operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetCertificateAuthorityCertificate for more information on using the GetCertificateAuthorityCertificate -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetCertificateAuthorityCertificateRequest method. -// req, resp := client.GetCertificateAuthorityCertificateRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificateAuthorityCertificate -func (c *ACMPCA) GetCertificateAuthorityCertificateRequest(input *GetCertificateAuthorityCertificateInput) (req *request.Request, output *GetCertificateAuthorityCertificateOutput) { - op := &request.Operation{ - Name: opGetCertificateAuthorityCertificate, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &GetCertificateAuthorityCertificateInput{} - } - - output = &GetCertificateAuthorityCertificateOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetCertificateAuthorityCertificate API operation for AWS Certificate Manager Private Certificate Authority. -// -// Retrieves the certificate and certificate chain for your private certificate -// authority (CA). Both the certificate and the chain are base64 PEM-encoded. -// The chain does not include the CA certificate. Each certificate in the chain -// signs the one before it. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation GetCertificateAuthorityCertificate for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificateAuthorityCertificate -func (c *ACMPCA) GetCertificateAuthorityCertificate(input *GetCertificateAuthorityCertificateInput) (*GetCertificateAuthorityCertificateOutput, error) { - req, out := c.GetCertificateAuthorityCertificateRequest(input) - return out, req.Send() -} - -// GetCertificateAuthorityCertificateWithContext is the same as GetCertificateAuthorityCertificate with the addition of -// the ability to pass a context and additional request options. -// -// See GetCertificateAuthorityCertificate for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) GetCertificateAuthorityCertificateWithContext(ctx aws.Context, input *GetCertificateAuthorityCertificateInput, opts ...request.Option) (*GetCertificateAuthorityCertificateOutput, error) { - req, out := c.GetCertificateAuthorityCertificateRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opGetCertificateAuthorityCsr = "GetCertificateAuthorityCsr" - -// GetCertificateAuthorityCsrRequest generates a "aws/request.Request" representing the -// client's request for the GetCertificateAuthorityCsr operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetCertificateAuthorityCsr for more information on using the GetCertificateAuthorityCsr -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetCertificateAuthorityCsrRequest method. -// req, resp := client.GetCertificateAuthorityCsrRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificateAuthorityCsr -func (c *ACMPCA) GetCertificateAuthorityCsrRequest(input *GetCertificateAuthorityCsrInput) (req *request.Request, output *GetCertificateAuthorityCsrOutput) { - op := &request.Operation{ - Name: opGetCertificateAuthorityCsr, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &GetCertificateAuthorityCsrInput{} - } - - output = &GetCertificateAuthorityCsrOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetCertificateAuthorityCsr API operation for AWS Certificate Manager Private Certificate Authority. -// -// Retrieves the certificate signing request (CSR) for your private certificate -// authority (CA). The CSR is created when you call the CreateCertificateAuthority -// action. Sign the CSR with your ACM Private CA-hosted or on-premises root -// or subordinate CA. Then import the signed certificate back into ACM Private -// CA by calling the ImportCertificateAuthorityCertificate action. The CSR is -// returned as a base64 PEM-encoded string. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation GetCertificateAuthorityCsr for usage and error information. -// -// Returned Error Codes: -// * ErrCodeRequestInProgressException "RequestInProgressException" -// Your request is already in progress. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/GetCertificateAuthorityCsr -func (c *ACMPCA) GetCertificateAuthorityCsr(input *GetCertificateAuthorityCsrInput) (*GetCertificateAuthorityCsrOutput, error) { - req, out := c.GetCertificateAuthorityCsrRequest(input) - return out, req.Send() -} - -// GetCertificateAuthorityCsrWithContext is the same as GetCertificateAuthorityCsr with the addition of -// the ability to pass a context and additional request options. -// -// See GetCertificateAuthorityCsr for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) GetCertificateAuthorityCsrWithContext(ctx aws.Context, input *GetCertificateAuthorityCsrInput, opts ...request.Option) (*GetCertificateAuthorityCsrOutput, error) { - req, out := c.GetCertificateAuthorityCsrRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opImportCertificateAuthorityCertificate = "ImportCertificateAuthorityCertificate" - -// ImportCertificateAuthorityCertificateRequest generates a "aws/request.Request" representing the -// client's request for the ImportCertificateAuthorityCertificate operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ImportCertificateAuthorityCertificate for more information on using the ImportCertificateAuthorityCertificate -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ImportCertificateAuthorityCertificateRequest method. -// req, resp := client.ImportCertificateAuthorityCertificateRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ImportCertificateAuthorityCertificate -func (c *ACMPCA) ImportCertificateAuthorityCertificateRequest(input *ImportCertificateAuthorityCertificateInput) (req *request.Request, output *ImportCertificateAuthorityCertificateOutput) { - op := &request.Operation{ - Name: opImportCertificateAuthorityCertificate, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ImportCertificateAuthorityCertificateInput{} - } - - output = &ImportCertificateAuthorityCertificateOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// ImportCertificateAuthorityCertificate API operation for AWS Certificate Manager Private Certificate Authority. -// -// Imports a signed private CA certificate into ACM Private CA. This action -// is used when you are using a chain of trust whose root is located outside -// ACM Private CA. Before you can call this action, the following preparations -// must in place: -// -// In ACM Private CA, call the CreateCertificateAuthority action to create the -// private CA that that you plan to back with the imported certificate. -// -// Call the GetCertificateAuthorityCsr action to generate a certificate signing -// request (CSR). -// -// Sign the CSR using a root or intermediate CA hosted either by an on-premises -// PKI hierarchy or a commercial CA.. -// -// Create a certificate chain and copy the signed certificate and the certificate -// chain to your working directory. -// -// The following requirements apply when you import a CA certificate. -// -// * You cannot import a non-self-signed certificate for use as a root CA. -// -// * You cannot import a self-signed certificate for use as a subordinate -// CA. -// -// * Your certificate chain must not include the private CA certificate that -// you are importing. -// -// * Your ACM Private CA-hosted or on-premises CA certificate must be the -// last certificate in your chain. The subordinate certificate, if any, that -// your root CA signed must be next to last. The subordinate certificate -// signed by the preceding subordinate CA must come next, and so on until -// your chain is built. -// -// * The chain must be PEM-encoded. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation ImportCertificateAuthorityCertificate for usage and error information. -// -// Returned Error Codes: -// * ErrCodeConcurrentModificationException "ConcurrentModificationException" -// A previous update to your private CA is still ongoing. -// -// * ErrCodeRequestInProgressException "RequestInProgressException" -// Your request is already in progress. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidRequestException "InvalidRequestException" -// The request action cannot be performed or is prohibited. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeMalformedCertificateException "MalformedCertificateException" -// One or more fields in the certificate are invalid. -// -// * ErrCodeCertificateMismatchException "CertificateMismatchException" -// The certificate authority certificate you are importing does not comply with -// conditions specified in the certificate that signed it. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ImportCertificateAuthorityCertificate -func (c *ACMPCA) ImportCertificateAuthorityCertificate(input *ImportCertificateAuthorityCertificateInput) (*ImportCertificateAuthorityCertificateOutput, error) { - req, out := c.ImportCertificateAuthorityCertificateRequest(input) - return out, req.Send() -} - -// ImportCertificateAuthorityCertificateWithContext is the same as ImportCertificateAuthorityCertificate with the addition of -// the ability to pass a context and additional request options. -// -// See ImportCertificateAuthorityCertificate for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ImportCertificateAuthorityCertificateWithContext(ctx aws.Context, input *ImportCertificateAuthorityCertificateInput, opts ...request.Option) (*ImportCertificateAuthorityCertificateOutput, error) { - req, out := c.ImportCertificateAuthorityCertificateRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opIssueCertificate = "IssueCertificate" - -// IssueCertificateRequest generates a "aws/request.Request" representing the -// client's request for the IssueCertificate operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See IssueCertificate for more information on using the IssueCertificate -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the IssueCertificateRequest method. -// req, resp := client.IssueCertificateRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/IssueCertificate -func (c *ACMPCA) IssueCertificateRequest(input *IssueCertificateInput) (req *request.Request, output *IssueCertificateOutput) { - op := &request.Operation{ - Name: opIssueCertificate, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &IssueCertificateInput{} - } - - output = &IssueCertificateOutput{} - req = c.newRequest(op, input, output) - return -} - -// IssueCertificate API operation for AWS Certificate Manager Private Certificate Authority. -// -// Uses your private certificate authority (CA) to issue a client certificate. -// This action returns the Amazon Resource Name (ARN) of the certificate. You -// can retrieve the certificate by calling the GetCertificate action and specifying -// the ARN. -// -// You cannot use the ACM ListCertificateAuthorities action to retrieve the -// ARNs of the certificates that you issue by using ACM Private CA. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation IssueCertificate for usage and error information. -// -// Returned Error Codes: -// * ErrCodeLimitExceededException "LimitExceededException" -// An ACM Private CA limit has been exceeded. See the exception message returned -// to determine the limit that was exceeded. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidArgsException "InvalidArgsException" -// One or more of the specified arguments was not valid. -// -// * ErrCodeMalformedCSRException "MalformedCSRException" -// The certificate signing request is invalid. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/IssueCertificate -func (c *ACMPCA) IssueCertificate(input *IssueCertificateInput) (*IssueCertificateOutput, error) { - req, out := c.IssueCertificateRequest(input) - return out, req.Send() -} - -// IssueCertificateWithContext is the same as IssueCertificate with the addition of -// the ability to pass a context and additional request options. -// -// See IssueCertificate for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) IssueCertificateWithContext(ctx aws.Context, input *IssueCertificateInput, opts ...request.Option) (*IssueCertificateOutput, error) { - req, out := c.IssueCertificateRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opListCertificateAuthorities = "ListCertificateAuthorities" - -// ListCertificateAuthoritiesRequest generates a "aws/request.Request" representing the -// client's request for the ListCertificateAuthorities operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ListCertificateAuthorities for more information on using the ListCertificateAuthorities -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ListCertificateAuthoritiesRequest method. -// req, resp := client.ListCertificateAuthoritiesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListCertificateAuthorities -func (c *ACMPCA) ListCertificateAuthoritiesRequest(input *ListCertificateAuthoritiesInput) (req *request.Request, output *ListCertificateAuthoritiesOutput) { - op := &request.Operation{ - Name: opListCertificateAuthorities, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &ListCertificateAuthoritiesInput{} - } - - output = &ListCertificateAuthoritiesOutput{} - req = c.newRequest(op, input, output) - return -} - -// ListCertificateAuthorities API operation for AWS Certificate Manager Private Certificate Authority. -// -// Lists the private certificate authorities that you created by using the CreateCertificateAuthority -// action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation ListCertificateAuthorities for usage and error information. -// -// Returned Error Codes: -// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The token specified in the NextToken argument is not valid. Use the token -// returned from your previous call to ListCertificateAuthorities. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListCertificateAuthorities -func (c *ACMPCA) ListCertificateAuthorities(input *ListCertificateAuthoritiesInput) (*ListCertificateAuthoritiesOutput, error) { - req, out := c.ListCertificateAuthoritiesRequest(input) - return out, req.Send() -} - -// ListCertificateAuthoritiesWithContext is the same as ListCertificateAuthorities with the addition of -// the ability to pass a context and additional request options. -// -// See ListCertificateAuthorities for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListCertificateAuthoritiesWithContext(ctx aws.Context, input *ListCertificateAuthoritiesInput, opts ...request.Option) (*ListCertificateAuthoritiesOutput, error) { - req, out := c.ListCertificateAuthoritiesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// ListCertificateAuthoritiesPages iterates over the pages of a ListCertificateAuthorities operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListCertificateAuthorities method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListCertificateAuthorities operation. -// pageNum := 0 -// err := client.ListCertificateAuthoritiesPages(params, -// func(page *acmpca.ListCertificateAuthoritiesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *ACMPCA) ListCertificateAuthoritiesPages(input *ListCertificateAuthoritiesInput, fn func(*ListCertificateAuthoritiesOutput, bool) bool) error { - return c.ListCertificateAuthoritiesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListCertificateAuthoritiesPagesWithContext same as ListCertificateAuthoritiesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListCertificateAuthoritiesPagesWithContext(ctx aws.Context, input *ListCertificateAuthoritiesInput, fn func(*ListCertificateAuthoritiesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListCertificateAuthoritiesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListCertificateAuthoritiesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListCertificateAuthoritiesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListPermissions = "ListPermissions" - -// ListPermissionsRequest generates a "aws/request.Request" representing the -// client's request for the ListPermissions operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ListPermissions for more information on using the ListPermissions -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ListPermissionsRequest method. -// req, resp := client.ListPermissionsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListPermissions -func (c *ACMPCA) ListPermissionsRequest(input *ListPermissionsInput) (req *request.Request, output *ListPermissionsOutput) { - op := &request.Operation{ - Name: opListPermissions, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &ListPermissionsInput{} - } - - output = &ListPermissionsOutput{} - req = c.newRequest(op, input, output) - return -} - -// ListPermissions API operation for AWS Certificate Manager Private Certificate Authority. -// -// Lists all the permissions, if any, that have been assigned by a private CA. -// Permissions can be granted with the CreatePermission action and revoked with -// the DeletePermission action. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation ListPermissions for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidNextTokenException "InvalidNextTokenException" -// The token specified in the NextToken argument is not valid. Use the token -// returned from your previous call to ListCertificateAuthorities. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListPermissions -func (c *ACMPCA) ListPermissions(input *ListPermissionsInput) (*ListPermissionsOutput, error) { - req, out := c.ListPermissionsRequest(input) - return out, req.Send() -} - -// ListPermissionsWithContext is the same as ListPermissions with the addition of -// the ability to pass a context and additional request options. -// -// See ListPermissions for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListPermissionsWithContext(ctx aws.Context, input *ListPermissionsInput, opts ...request.Option) (*ListPermissionsOutput, error) { - req, out := c.ListPermissionsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// ListPermissionsPages iterates over the pages of a ListPermissions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListPermissions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListPermissions operation. -// pageNum := 0 -// err := client.ListPermissionsPages(params, -// func(page *acmpca.ListPermissionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *ACMPCA) ListPermissionsPages(input *ListPermissionsInput, fn func(*ListPermissionsOutput, bool) bool) error { - return c.ListPermissionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListPermissionsPagesWithContext same as ListPermissionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListPermissionsPagesWithContext(ctx aws.Context, input *ListPermissionsInput, fn func(*ListPermissionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListPermissionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListPermissionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListPermissionsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opListTags = "ListTags" - -// ListTagsRequest generates a "aws/request.Request" representing the -// client's request for the ListTags operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ListTags for more information on using the ListTags -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ListTagsRequest method. -// req, resp := client.ListTagsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListTags -func (c *ACMPCA) ListTagsRequest(input *ListTagsInput) (req *request.Request, output *ListTagsOutput) { - op := &request.Operation{ - Name: opListTags, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &ListTagsInput{} - } - - output = &ListTagsOutput{} - req = c.newRequest(op, input, output) - return -} - -// ListTags API operation for AWS Certificate Manager Private Certificate Authority. -// -// Lists the tags, if any, that are associated with your private CA. Tags are -// labels that you can use to identify and organize your CAs. Each tag consists -// of a key and an optional value. Call the TagCertificateAuthority action to -// add one or more tags to your CA. Call the UntagCertificateAuthority action -// to remove tags. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation ListTags for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/ListTags -func (c *ACMPCA) ListTags(input *ListTagsInput) (*ListTagsOutput, error) { - req, out := c.ListTagsRequest(input) - return out, req.Send() -} - -// ListTagsWithContext is the same as ListTags with the addition of -// the ability to pass a context and additional request options. -// -// See ListTags for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListTagsWithContext(ctx aws.Context, input *ListTagsInput, opts ...request.Option) (*ListTagsOutput, error) { - req, out := c.ListTagsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// ListTagsPages iterates over the pages of a ListTags operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListTags method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a ListTags operation. -// pageNum := 0 -// err := client.ListTagsPages(params, -// func(page *acmpca.ListTagsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *ACMPCA) ListTagsPages(input *ListTagsInput, fn func(*ListTagsOutput, bool) bool) error { - return c.ListTagsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListTagsPagesWithContext same as ListTagsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) ListTagsPagesWithContext(ctx aws.Context, input *ListTagsInput, fn func(*ListTagsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListTagsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListTagsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*ListTagsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opRestoreCertificateAuthority = "RestoreCertificateAuthority" - -// RestoreCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the RestoreCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See RestoreCertificateAuthority for more information on using the RestoreCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the RestoreCertificateAuthorityRequest method. -// req, resp := client.RestoreCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/RestoreCertificateAuthority -func (c *ACMPCA) RestoreCertificateAuthorityRequest(input *RestoreCertificateAuthorityInput) (req *request.Request, output *RestoreCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opRestoreCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &RestoreCertificateAuthorityInput{} - } - - output = &RestoreCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// RestoreCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Restores a certificate authority (CA) that is in the DELETED state. You can -// restore a CA during the period that you defined in the PermanentDeletionTimeInDays -// parameter of the DeleteCertificateAuthority action. Currently, you can specify -// 7 to 30 days. If you did not specify a PermanentDeletionTimeInDays value, -// by default you can restore the CA at any time in a 30 day period. You can -// check the time remaining in the restoration period of a private CA in the -// DELETED state by calling the DescribeCertificateAuthority or ListCertificateAuthorities -// actions. The status of a restored CA is set to its pre-deletion status when -// the RestoreCertificateAuthority action returns. To change its status to ACTIVE, -// call the UpdateCertificateAuthority action. If the private CA was in the -// PENDING_CERTIFICATE state at deletion, you must use the ImportCertificateAuthorityCertificate -// action to import a certificate authority into the private CA before it can -// be activated. You cannot restore a CA after the restoration period has ended. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation RestoreCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/RestoreCertificateAuthority -func (c *ACMPCA) RestoreCertificateAuthority(input *RestoreCertificateAuthorityInput) (*RestoreCertificateAuthorityOutput, error) { - req, out := c.RestoreCertificateAuthorityRequest(input) - return out, req.Send() -} - -// RestoreCertificateAuthorityWithContext is the same as RestoreCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See RestoreCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) RestoreCertificateAuthorityWithContext(ctx aws.Context, input *RestoreCertificateAuthorityInput, opts ...request.Option) (*RestoreCertificateAuthorityOutput, error) { - req, out := c.RestoreCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opRevokeCertificate = "RevokeCertificate" - -// RevokeCertificateRequest generates a "aws/request.Request" representing the -// client's request for the RevokeCertificate operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See RevokeCertificate for more information on using the RevokeCertificate -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the RevokeCertificateRequest method. -// req, resp := client.RevokeCertificateRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/RevokeCertificate -func (c *ACMPCA) RevokeCertificateRequest(input *RevokeCertificateInput) (req *request.Request, output *RevokeCertificateOutput) { - op := &request.Operation{ - Name: opRevokeCertificate, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &RevokeCertificateInput{} - } - - output = &RevokeCertificateOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// RevokeCertificate API operation for AWS Certificate Manager Private Certificate Authority. -// -// Revokes a certificate that was issued inside ACM Private CA. If you enable -// a certificate revocation list (CRL) when you create or update your private -// CA, information about the revoked certificates will be included in the CRL. -// ACM Private CA writes the CRL to an S3 bucket that you specify. For more -// information about revocation, see the CrlConfiguration structure. ACM Private -// CA also writes revocation information to the audit report. For more information, -// see CreateCertificateAuthorityAuditReport. -// -// You cannot revoke a root CA self-signed certificate. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation RevokeCertificate for usage and error information. -// -// Returned Error Codes: -// * ErrCodeConcurrentModificationException "ConcurrentModificationException" -// A previous update to your private CA is still ongoing. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidRequestException "InvalidRequestException" -// The request action cannot be performed or is prohibited. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeLimitExceededException "LimitExceededException" -// An ACM Private CA limit has been exceeded. See the exception message returned -// to determine the limit that was exceeded. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeRequestAlreadyProcessedException "RequestAlreadyProcessedException" -// Your request has already been completed. -// -// * ErrCodeRequestInProgressException "RequestInProgressException" -// Your request is already in progress. -// -// * ErrCodeRequestFailedException "RequestFailedException" -// The request has failed for an unspecified reason. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/RevokeCertificate -func (c *ACMPCA) RevokeCertificate(input *RevokeCertificateInput) (*RevokeCertificateOutput, error) { - req, out := c.RevokeCertificateRequest(input) - return out, req.Send() -} - -// RevokeCertificateWithContext is the same as RevokeCertificate with the addition of -// the ability to pass a context and additional request options. -// -// See RevokeCertificate for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) RevokeCertificateWithContext(ctx aws.Context, input *RevokeCertificateInput, opts ...request.Option) (*RevokeCertificateOutput, error) { - req, out := c.RevokeCertificateRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opTagCertificateAuthority = "TagCertificateAuthority" - -// TagCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the TagCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See TagCertificateAuthority for more information on using the TagCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the TagCertificateAuthorityRequest method. -// req, resp := client.TagCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/TagCertificateAuthority -func (c *ACMPCA) TagCertificateAuthorityRequest(input *TagCertificateAuthorityInput) (req *request.Request, output *TagCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opTagCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &TagCertificateAuthorityInput{} - } - - output = &TagCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// TagCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Adds one or more tags to your private CA. Tags are labels that you can use -// to identify and organize your AWS resources. Each tag consists of a key and -// an optional value. You specify the private CA on input by its Amazon Resource -// Name (ARN). You specify the tag by using a key-value pair. You can apply -// a tag to just one private CA if you want to identify a specific characteristic -// of that CA, or you can apply the same tag to multiple private CAs if you -// want to filter for a common relationship among those CAs. To remove one or -// more tags, use the UntagCertificateAuthority action. Call the ListTags action -// to see what tags are associated with your CA. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation TagCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidTagException "InvalidTagException" -// The tag associated with the CA is not valid. The invalid argument is contained -// in the message field. -// -// * ErrCodeTooManyTagsException "TooManyTagsException" -// You can associate up to 50 tags with a private CA. Exception information -// is contained in the exception message field. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/TagCertificateAuthority -func (c *ACMPCA) TagCertificateAuthority(input *TagCertificateAuthorityInput) (*TagCertificateAuthorityOutput, error) { - req, out := c.TagCertificateAuthorityRequest(input) - return out, req.Send() -} - -// TagCertificateAuthorityWithContext is the same as TagCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See TagCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) TagCertificateAuthorityWithContext(ctx aws.Context, input *TagCertificateAuthorityInput, opts ...request.Option) (*TagCertificateAuthorityOutput, error) { - req, out := c.TagCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opUntagCertificateAuthority = "UntagCertificateAuthority" - -// UntagCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the UntagCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See UntagCertificateAuthority for more information on using the UntagCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the UntagCertificateAuthorityRequest method. -// req, resp := client.UntagCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/UntagCertificateAuthority -func (c *ACMPCA) UntagCertificateAuthorityRequest(input *UntagCertificateAuthorityInput) (req *request.Request, output *UntagCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opUntagCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &UntagCertificateAuthorityInput{} - } - - output = &UntagCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// UntagCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Remove one or more tags from your private CA. A tag consists of a key-value -// pair. If you do not specify the value portion of the tag when calling this -// action, the tag will be removed regardless of value. If you specify a value, -// the tag is removed only if it is associated with the specified value. To -// add tags to a private CA, use the TagCertificateAuthority. Call the ListTags -// action to see what tags are associated with your CA. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation UntagCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidTagException "InvalidTagException" -// The tag associated with the CA is not valid. The invalid argument is contained -// in the message field. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/UntagCertificateAuthority -func (c *ACMPCA) UntagCertificateAuthority(input *UntagCertificateAuthorityInput) (*UntagCertificateAuthorityOutput, error) { - req, out := c.UntagCertificateAuthorityRequest(input) - return out, req.Send() -} - -// UntagCertificateAuthorityWithContext is the same as UntagCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See UntagCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) UntagCertificateAuthorityWithContext(ctx aws.Context, input *UntagCertificateAuthorityInput, opts ...request.Option) (*UntagCertificateAuthorityOutput, error) { - req, out := c.UntagCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opUpdateCertificateAuthority = "UpdateCertificateAuthority" - -// UpdateCertificateAuthorityRequest generates a "aws/request.Request" representing the -// client's request for the UpdateCertificateAuthority operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See UpdateCertificateAuthority for more information on using the UpdateCertificateAuthority -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the UpdateCertificateAuthorityRequest method. -// req, resp := client.UpdateCertificateAuthorityRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/UpdateCertificateAuthority -func (c *ACMPCA) UpdateCertificateAuthorityRequest(input *UpdateCertificateAuthorityInput) (req *request.Request, output *UpdateCertificateAuthorityOutput) { - op := &request.Operation{ - Name: opUpdateCertificateAuthority, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &UpdateCertificateAuthorityInput{} - } - - output = &UpdateCertificateAuthorityOutput{} - req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) - return -} - -// UpdateCertificateAuthority API operation for AWS Certificate Manager Private Certificate Authority. -// -// Updates the status or configuration of a private certificate authority (CA). -// Your private CA must be in the ACTIVE or DISABLED state before you can update -// it. You can disable a private CA that is in the ACTIVE state or make a CA -// that is in the DISABLED state active again. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for AWS Certificate Manager Private Certificate Authority's -// API operation UpdateCertificateAuthority for usage and error information. -// -// Returned Error Codes: -// * ErrCodeConcurrentModificationException "ConcurrentModificationException" -// A previous update to your private CA is still ongoing. -// -// * ErrCodeResourceNotFoundException "ResourceNotFoundException" -// A resource such as a private CA, S3 bucket, certificate, or audit report -// cannot be found. -// -// * ErrCodeInvalidArgsException "InvalidArgsException" -// One or more of the specified arguments was not valid. -// -// * ErrCodeInvalidArnException "InvalidArnException" -// The requested Amazon Resource Name (ARN) does not refer to an existing resource. -// -// * ErrCodeInvalidStateException "InvalidStateException" -// The private CA is in a state during which a report or certificate cannot -// be generated. -// -// * ErrCodeInvalidPolicyException "InvalidPolicyException" -// The S3 bucket policy is not valid. The policy must give ACM Private CA rights -// to read from and write to the bucket and find the bucket location. -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22/UpdateCertificateAuthority -func (c *ACMPCA) UpdateCertificateAuthority(input *UpdateCertificateAuthorityInput) (*UpdateCertificateAuthorityOutput, error) { - req, out := c.UpdateCertificateAuthorityRequest(input) - return out, req.Send() -} - -// UpdateCertificateAuthorityWithContext is the same as UpdateCertificateAuthority with the addition of -// the ability to pass a context and additional request options. -// -// See UpdateCertificateAuthority for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) UpdateCertificateAuthorityWithContext(ctx aws.Context, input *UpdateCertificateAuthorityInput, opts ...request.Option) (*UpdateCertificateAuthorityOutput, error) { - req, out := c.UpdateCertificateAuthorityRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// Contains information about the certificate subject. The certificate can be -// one issued by your private certificate authority (CA) or it can be your private -// CA certificate. The Subject field in the certificate identifies the entity -// that owns or controls the public key in the certificate. The entity can be -// a user, computer, device, or service. The Subject must contain an X.500 distinguished -// name (DN). A DN is a sequence of relative distinguished names (RDNs). The -// RDNs are separated by commas in the certificate. The DN must be unique for -// each entity, but your private CA can issue more than one certificate with -// the same DN to the same entity. -type ASN1Subject struct { - _ struct{} `type:"structure"` - - // Fully qualified domain name (FQDN) associated with the certificate subject. - CommonName *string `type:"string"` - - // Two-digit code that specifies the country in which the certificate subject - // located. - Country *string `type:"string"` - - // Disambiguating information for the certificate subject. - DistinguishedNameQualifier *string `type:"string"` - - // Typically a qualifier appended to the name of an individual. Examples include - // Jr. for junior, Sr. for senior, and III for third. - GenerationQualifier *string `type:"string"` - - // First name. - GivenName *string `type:"string"` - - // Concatenation that typically contains the first letter of the GivenName, - // the first letter of the middle name if one exists, and the first letter of - // the SurName. - Initials *string `type:"string"` - - // The locality (such as a city or town) in which the certificate subject is - // located. - Locality *string `type:"string"` - - // Legal name of the organization with which the certificate subject is affiliated. - Organization *string `type:"string"` - - // A subdivision or unit of the organization (such as sales or finance) with - // which the certificate subject is affiliated. - OrganizationalUnit *string `type:"string"` - - // Typically a shortened version of a longer GivenName. For example, Jonathan - // is often shortened to John. Elizabeth is often shortened to Beth, Liz, or - // Eliza. - Pseudonym *string `type:"string"` - - // The certificate serial number. - SerialNumber *string `type:"string"` - - // State in which the subject of the certificate is located. - State *string `type:"string"` - - // Family name. In the US and the UK, for example, the surname of an individual - // is ordered last. In Asian cultures the surname is typically ordered first. - Surname *string `type:"string"` - - // A title such as Mr. or Ms., which is pre-pended to the name to refer formally - // to the certificate subject. - Title *string `type:"string"` -} - -// String returns the string representation -func (s ASN1Subject) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ASN1Subject) GoString() string { - return s.String() -} - -// SetCommonName sets the CommonName field's value. -func (s *ASN1Subject) SetCommonName(v string) *ASN1Subject { - s.CommonName = &v - return s -} - -// SetCountry sets the Country field's value. -func (s *ASN1Subject) SetCountry(v string) *ASN1Subject { - s.Country = &v - return s -} - -// SetDistinguishedNameQualifier sets the DistinguishedNameQualifier field's value. -func (s *ASN1Subject) SetDistinguishedNameQualifier(v string) *ASN1Subject { - s.DistinguishedNameQualifier = &v - return s -} - -// SetGenerationQualifier sets the GenerationQualifier field's value. -func (s *ASN1Subject) SetGenerationQualifier(v string) *ASN1Subject { - s.GenerationQualifier = &v - return s -} - -// SetGivenName sets the GivenName field's value. -func (s *ASN1Subject) SetGivenName(v string) *ASN1Subject { - s.GivenName = &v - return s -} - -// SetInitials sets the Initials field's value. -func (s *ASN1Subject) SetInitials(v string) *ASN1Subject { - s.Initials = &v - return s -} - -// SetLocality sets the Locality field's value. -func (s *ASN1Subject) SetLocality(v string) *ASN1Subject { - s.Locality = &v - return s -} - -// SetOrganization sets the Organization field's value. -func (s *ASN1Subject) SetOrganization(v string) *ASN1Subject { - s.Organization = &v - return s -} - -// SetOrganizationalUnit sets the OrganizationalUnit field's value. -func (s *ASN1Subject) SetOrganizationalUnit(v string) *ASN1Subject { - s.OrganizationalUnit = &v - return s -} - -// SetPseudonym sets the Pseudonym field's value. -func (s *ASN1Subject) SetPseudonym(v string) *ASN1Subject { - s.Pseudonym = &v - return s -} - -// SetSerialNumber sets the SerialNumber field's value. -func (s *ASN1Subject) SetSerialNumber(v string) *ASN1Subject { - s.SerialNumber = &v - return s -} - -// SetState sets the State field's value. -func (s *ASN1Subject) SetState(v string) *ASN1Subject { - s.State = &v - return s -} - -// SetSurname sets the Surname field's value. -func (s *ASN1Subject) SetSurname(v string) *ASN1Subject { - s.Surname = &v - return s -} - -// SetTitle sets the Title field's value. -func (s *ASN1Subject) SetTitle(v string) *ASN1Subject { - s.Title = &v - return s -} - -// Contains information about your private certificate authority (CA). Your -// private CA can issue and revoke X.509 digital certificates. Digital certificates -// verify that the entity named in the certificate Subject field owns or controls -// the public key contained in the Subject Public Key Info field. Call the CreateCertificateAuthority -// action to create your private CA. You must then call the GetCertificateAuthorityCertificate -// action to retrieve a private CA certificate signing request (CSR). Sign the -// CSR with your ACM Private CA-hosted or on-premises root or subordinate CA -// certificate. Call the ImportCertificateAuthorityCertificate action to import -// the signed certificate into AWS Certificate Manager (ACM). -type CertificateAuthority struct { - _ struct{} `type:"structure"` - - // Amazon Resource Name (ARN) for your private certificate authority (CA). The - // format is 12345678-1234-1234-1234-123456789012 . - Arn *string `min:"5" type:"string"` - - // Your private CA configuration. - CertificateAuthorityConfiguration *CertificateAuthorityConfiguration `type:"structure"` - - // Date and time at which your private CA was created. - CreatedAt *time.Time `type:"timestamp"` - - // Reason the request to create your private CA failed. - FailureReason *string `type:"string" enum:"FailureReason"` - - // Date and time at which your private CA was last updated. - LastStateChangeAt *time.Time `type:"timestamp"` - - // Date and time after which your private CA certificate is not valid. - NotAfter *time.Time `type:"timestamp"` - - // Date and time before which your private CA certificate is not valid. - NotBefore *time.Time `type:"timestamp"` - - // The period during which a deleted CA can be restored. For more information, - // see the PermanentDeletionTimeInDays parameter of the DeleteCertificateAuthorityRequest - // action. - RestorableUntil *time.Time `type:"timestamp"` - - // Information about the certificate revocation list (CRL) created and maintained - // by your private CA. - RevocationConfiguration *RevocationConfiguration `type:"structure"` - - // Serial number of your private CA. - Serial *string `type:"string"` - - // Status of your private CA. - Status *string `type:"string" enum:"CertificateAuthorityStatus"` - - // Type of your private CA. - Type *string `type:"string" enum:"CertificateAuthorityType"` -} - -// String returns the string representation -func (s CertificateAuthority) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CertificateAuthority) GoString() string { - return s.String() -} - -// SetArn sets the Arn field's value. -func (s *CertificateAuthority) SetArn(v string) *CertificateAuthority { - s.Arn = &v - return s -} - -// SetCertificateAuthorityConfiguration sets the CertificateAuthorityConfiguration field's value. -func (s *CertificateAuthority) SetCertificateAuthorityConfiguration(v *CertificateAuthorityConfiguration) *CertificateAuthority { - s.CertificateAuthorityConfiguration = v - return s -} - -// SetCreatedAt sets the CreatedAt field's value. -func (s *CertificateAuthority) SetCreatedAt(v time.Time) *CertificateAuthority { - s.CreatedAt = &v - return s -} - -// SetFailureReason sets the FailureReason field's value. -func (s *CertificateAuthority) SetFailureReason(v string) *CertificateAuthority { - s.FailureReason = &v - return s -} - -// SetLastStateChangeAt sets the LastStateChangeAt field's value. -func (s *CertificateAuthority) SetLastStateChangeAt(v time.Time) *CertificateAuthority { - s.LastStateChangeAt = &v - return s -} - -// SetNotAfter sets the NotAfter field's value. -func (s *CertificateAuthority) SetNotAfter(v time.Time) *CertificateAuthority { - s.NotAfter = &v - return s -} - -// SetNotBefore sets the NotBefore field's value. -func (s *CertificateAuthority) SetNotBefore(v time.Time) *CertificateAuthority { - s.NotBefore = &v - return s -} - -// SetRestorableUntil sets the RestorableUntil field's value. -func (s *CertificateAuthority) SetRestorableUntil(v time.Time) *CertificateAuthority { - s.RestorableUntil = &v - return s -} - -// SetRevocationConfiguration sets the RevocationConfiguration field's value. -func (s *CertificateAuthority) SetRevocationConfiguration(v *RevocationConfiguration) *CertificateAuthority { - s.RevocationConfiguration = v - return s -} - -// SetSerial sets the Serial field's value. -func (s *CertificateAuthority) SetSerial(v string) *CertificateAuthority { - s.Serial = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *CertificateAuthority) SetStatus(v string) *CertificateAuthority { - s.Status = &v - return s -} - -// SetType sets the Type field's value. -func (s *CertificateAuthority) SetType(v string) *CertificateAuthority { - s.Type = &v - return s -} - -// Contains configuration information for your private certificate authority -// (CA). This includes information about the class of public key algorithm and -// the key pair that your private CA creates when it issues a certificate. It -// also includes the signature algorithm that it uses when issuing certificates, -// and its X.500 distinguished name. You must specify this information when -// you call the CreateCertificateAuthority action. -type CertificateAuthorityConfiguration struct { - _ struct{} `type:"structure"` - - // Type of the public key algorithm and size, in bits, of the key pair that - // your CA creates when it issues a certificate. When you create a subordinate - // CA, you must use a key algorithm supported by the parent CA. - // - // KeyAlgorithm is a required field - KeyAlgorithm *string `type:"string" required:"true" enum:"KeyAlgorithm"` - - // Name of the algorithm your private CA uses to sign certificate requests. - // - // SigningAlgorithm is a required field - SigningAlgorithm *string `type:"string" required:"true" enum:"SigningAlgorithm"` - - // Structure that contains X.500 distinguished name information for your private - // CA. - // - // Subject is a required field - Subject *ASN1Subject `type:"structure" required:"true"` -} - -// String returns the string representation -func (s CertificateAuthorityConfiguration) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CertificateAuthorityConfiguration) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CertificateAuthorityConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CertificateAuthorityConfiguration"} - if s.KeyAlgorithm == nil { - invalidParams.Add(request.NewErrParamRequired("KeyAlgorithm")) - } - if s.SigningAlgorithm == nil { - invalidParams.Add(request.NewErrParamRequired("SigningAlgorithm")) - } - if s.Subject == nil { - invalidParams.Add(request.NewErrParamRequired("Subject")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetKeyAlgorithm sets the KeyAlgorithm field's value. -func (s *CertificateAuthorityConfiguration) SetKeyAlgorithm(v string) *CertificateAuthorityConfiguration { - s.KeyAlgorithm = &v - return s -} - -// SetSigningAlgorithm sets the SigningAlgorithm field's value. -func (s *CertificateAuthorityConfiguration) SetSigningAlgorithm(v string) *CertificateAuthorityConfiguration { - s.SigningAlgorithm = &v - return s -} - -// SetSubject sets the Subject field's value. -func (s *CertificateAuthorityConfiguration) SetSubject(v *ASN1Subject) *CertificateAuthorityConfiguration { - s.Subject = v - return s -} - -type CreateCertificateAuthorityAuditReportInput struct { - _ struct{} `type:"structure"` - - // The format in which to create the report. This can be either JSON or CSV. - // - // AuditReportResponseFormat is a required field - AuditReportResponseFormat *string `type:"string" required:"true" enum:"AuditReportResponseFormat"` - - // The Amazon Resource Name (ARN) of the CA to be audited. This is of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // The name of the S3 bucket that will contain the audit report. - // - // S3BucketName is a required field - S3BucketName *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateCertificateAuthorityAuditReportInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCertificateAuthorityAuditReportInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateCertificateAuthorityAuditReportInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateCertificateAuthorityAuditReportInput"} - if s.AuditReportResponseFormat == nil { - invalidParams.Add(request.NewErrParamRequired("AuditReportResponseFormat")) - } - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.S3BucketName == nil { - invalidParams.Add(request.NewErrParamRequired("S3BucketName")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAuditReportResponseFormat sets the AuditReportResponseFormat field's value. -func (s *CreateCertificateAuthorityAuditReportInput) SetAuditReportResponseFormat(v string) *CreateCertificateAuthorityAuditReportInput { - s.AuditReportResponseFormat = &v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *CreateCertificateAuthorityAuditReportInput) SetCertificateAuthorityArn(v string) *CreateCertificateAuthorityAuditReportInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetS3BucketName sets the S3BucketName field's value. -func (s *CreateCertificateAuthorityAuditReportInput) SetS3BucketName(v string) *CreateCertificateAuthorityAuditReportInput { - s.S3BucketName = &v - return s -} - -type CreateCertificateAuthorityAuditReportOutput struct { - _ struct{} `type:"structure"` - - // An alphanumeric string that contains a report identifier. - AuditReportId *string `min:"36" type:"string"` - - // The key that uniquely identifies the report file in your S3 bucket. - S3Key *string `type:"string"` -} - -// String returns the string representation -func (s CreateCertificateAuthorityAuditReportOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCertificateAuthorityAuditReportOutput) GoString() string { - return s.String() -} - -// SetAuditReportId sets the AuditReportId field's value. -func (s *CreateCertificateAuthorityAuditReportOutput) SetAuditReportId(v string) *CreateCertificateAuthorityAuditReportOutput { - s.AuditReportId = &v - return s -} - -// SetS3Key sets the S3Key field's value. -func (s *CreateCertificateAuthorityAuditReportOutput) SetS3Key(v string) *CreateCertificateAuthorityAuditReportOutput { - s.S3Key = &v - return s -} - -type CreateCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // Name and bit size of the private key algorithm, the name of the signing algorithm, - // and X.500 certificate subject information. - // - // CertificateAuthorityConfiguration is a required field - CertificateAuthorityConfiguration *CertificateAuthorityConfiguration `type:"structure" required:"true"` - - // The type of the certificate authority. - // - // CertificateAuthorityType is a required field - CertificateAuthorityType *string `type:"string" required:"true" enum:"CertificateAuthorityType"` - - // Alphanumeric string that can be used to distinguish between calls to CreateCertificateAuthority. - // Idempotency tokens time out after five minutes. Therefore, if you call CreateCertificateAuthority - // multiple times with the same idempotency token within a five minute period, - // ACM Private CA recognizes that you are requesting only one certificate. As - // a result, ACM Private CA issues only one. If you change the idempotency token - // for each call, however, ACM Private CA recognizes that you are requesting - // multiple certificates. - IdempotencyToken *string `min:"1" type:"string"` - - // Contains a Boolean value that you can use to enable a certification revocation - // list (CRL) for the CA, the name of the S3 bucket to which ACM Private CA - // will write the CRL, and an optional CNAME alias that you can use to hide - // the name of your bucket in the CRL Distribution Points extension of your - // CA certificate. For more information, see the CrlConfiguration structure. - RevocationConfiguration *RevocationConfiguration `type:"structure"` - - // Key-value pairs that will be attached to the new private CA. You can associate - // up to 50 tags with a private CA. For information using tags with - // - // IAM to manage permissions, see Controlling Access Using IAM Tags (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_iam-tags.html). - Tags []*Tag `min:"1" type:"list"` -} - -// String returns the string representation -func (s CreateCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateCertificateAuthorityInput"} - if s.CertificateAuthorityConfiguration == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityConfiguration")) - } - if s.CertificateAuthorityType == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityType")) - } - if s.IdempotencyToken != nil && len(*s.IdempotencyToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("IdempotencyToken", 1)) - } - if s.Tags != nil && len(s.Tags) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) - } - if s.CertificateAuthorityConfiguration != nil { - if err := s.CertificateAuthorityConfiguration.Validate(); err != nil { - invalidParams.AddNested("CertificateAuthorityConfiguration", err.(request.ErrInvalidParams)) - } - } - if s.RevocationConfiguration != nil { - if err := s.RevocationConfiguration.Validate(); err != nil { - invalidParams.AddNested("RevocationConfiguration", err.(request.ErrInvalidParams)) - } - } - if s.Tags != nil { - for i, v := range s.Tags { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) - } - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityConfiguration sets the CertificateAuthorityConfiguration field's value. -func (s *CreateCertificateAuthorityInput) SetCertificateAuthorityConfiguration(v *CertificateAuthorityConfiguration) *CreateCertificateAuthorityInput { - s.CertificateAuthorityConfiguration = v - return s -} - -// SetCertificateAuthorityType sets the CertificateAuthorityType field's value. -func (s *CreateCertificateAuthorityInput) SetCertificateAuthorityType(v string) *CreateCertificateAuthorityInput { - s.CertificateAuthorityType = &v - return s -} - -// SetIdempotencyToken sets the IdempotencyToken field's value. -func (s *CreateCertificateAuthorityInput) SetIdempotencyToken(v string) *CreateCertificateAuthorityInput { - s.IdempotencyToken = &v - return s -} - -// SetRevocationConfiguration sets the RevocationConfiguration field's value. -func (s *CreateCertificateAuthorityInput) SetRevocationConfiguration(v *RevocationConfiguration) *CreateCertificateAuthorityInput { - s.RevocationConfiguration = v - return s -} - -// SetTags sets the Tags field's value. -func (s *CreateCertificateAuthorityInput) SetTags(v []*Tag) *CreateCertificateAuthorityInput { - s.Tags = v - return s -} - -type CreateCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` - - // If successful, the Amazon Resource Name (ARN) of the certificate authority - // (CA). This is of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - CertificateAuthorityArn *string `min:"5" type:"string"` -} - -// String returns the string representation -func (s CreateCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCertificateAuthorityOutput) GoString() string { - return s.String() -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *CreateCertificateAuthorityOutput) SetCertificateAuthorityArn(v string) *CreateCertificateAuthorityOutput { - s.CertificateAuthorityArn = &v - return s -} - -type CreatePermissionInput struct { - _ struct{} `type:"structure"` - - // The actions that the specified AWS service principal can use. These include - // IssueCertificate, GetCertificate, and ListPermissions. - // - // Actions is a required field - Actions []*string `min:"1" type:"list" required:"true"` - - // The Amazon Resource Name (ARN) of the CA that grants the permissions. You - // can find the ARN by calling the ListCertificateAuthorities action. This must - // have the following form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // The AWS service or identity that receives the permission. At this time, the - // only valid principal is acm.amazonaws.com. - // - // Principal is a required field - Principal *string `type:"string" required:"true"` - - // The ID of the calling account. - SourceAccount *string `min:"12" type:"string"` -} - -// String returns the string representation -func (s CreatePermissionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreatePermissionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreatePermissionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreatePermissionInput"} - if s.Actions == nil { - invalidParams.Add(request.NewErrParamRequired("Actions")) - } - if s.Actions != nil && len(s.Actions) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Actions", 1)) - } - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.Principal == nil { - invalidParams.Add(request.NewErrParamRequired("Principal")) - } - if s.SourceAccount != nil && len(*s.SourceAccount) < 12 { - invalidParams.Add(request.NewErrParamMinLen("SourceAccount", 12)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetActions sets the Actions field's value. -func (s *CreatePermissionInput) SetActions(v []*string) *CreatePermissionInput { - s.Actions = v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *CreatePermissionInput) SetCertificateAuthorityArn(v string) *CreatePermissionInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetPrincipal sets the Principal field's value. -func (s *CreatePermissionInput) SetPrincipal(v string) *CreatePermissionInput { - s.Principal = &v - return s -} - -// SetSourceAccount sets the SourceAccount field's value. -func (s *CreatePermissionInput) SetSourceAccount(v string) *CreatePermissionInput { - s.SourceAccount = &v - return s -} - -type CreatePermissionOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s CreatePermissionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreatePermissionOutput) GoString() string { - return s.String() -} - -// Contains configuration information for a certificate revocation list (CRL). -// Your private certificate authority (CA) creates base CRLs. Delta CRLs are -// not supported. You can enable CRLs for your new or an existing private CA -// by setting the Enabled parameter to true. Your private CA writes CRLs to -// an S3 bucket that you specify in the S3BucketName parameter. You can hide -// the name of your bucket by specifying a value for the CustomCname parameter. -// Your private CA copies the CNAME or the S3 bucket name to the CRL Distribution -// Points extension of each certificate it issues. Your S3 bucket policy must -// give write permission to ACM Private CA. -// -// Your private CA uses the value in the ExpirationInDays parameter to calculate -// the nextUpdate field in the CRL. The CRL is refreshed at 1/2 the age of next -// update or when a certificate is revoked. When a certificate is revoked, it -// is recorded in the next CRL that is generated and in the next audit report. -// Only time valid certificates are listed in the CRL. Expired certificates -// are not included. -// -// CRLs contain the following fields: -// -// * Version: The current version number defined in RFC 5280 is V2. The integer -// value is 0x1. -// -// * Signature Algorithm: The name of the algorithm used to sign the CRL. -// -// * Issuer: The X.500 distinguished name of your private CA that issued -// the CRL. -// -// * Last Update: The issue date and time of this CRL. -// -// * Next Update: The day and time by which the next CRL will be issued. -// -// * Revoked Certificates: List of revoked certificates. Each list item contains -// the following information. Serial Number: The serial number, in hexadecimal -// format, of the revoked certificate. Revocation Date: Date and time the -// certificate was revoked. CRL Entry Extensions: Optional extensions for -// the CRL entry. X509v3 CRL Reason Code: Reason the certificate was revoked. -// -// * CRL Extensions: Optional extensions for the CRL. X509v3 Authority Key -// Identifier: Identifies the public key associated with the private key -// used to sign the certificate. X509v3 CRL Number:: Decimal sequence number -// for the CRL. -// -// * Signature Algorithm: Algorithm used by your private CA to sign the CRL. -// -// * Signature Value: Signature computed over the CRL. -// -// Certificate revocation lists created by ACM Private CA are DER-encoded. You -// can use the following OpenSSL command to list a CRL. -// -// openssl crl -inform DER -text -in crl_path -noout -type CrlConfiguration struct { - _ struct{} `type:"structure"` - - // Name inserted into the certificate CRL Distribution Points extension that - // enables the use of an alias for the CRL distribution point. Use this value - // if you don't want the name of your S3 bucket to be public. - CustomCname *string `type:"string"` - - // Boolean value that specifies whether certificate revocation lists (CRLs) - // are enabled. You can use this value to enable certificate revocation for - // a new CA when you call the CreateCertificateAuthority action or for an existing - // CA when you call the UpdateCertificateAuthority action. - // - // Enabled is a required field - Enabled *bool `type:"boolean" required:"true"` - - // Number of days until a certificate expires. - ExpirationInDays *int64 `min:"1" type:"integer"` - - // Name of the S3 bucket that contains the CRL. If you do not provide a value - // for the CustomCname argument, the name of your S3 bucket is placed into the - // CRL Distribution Points extension of the issued certificate. You can change - // the name of your bucket by calling the UpdateCertificateAuthority action. - // You must specify a bucket policy that allows ACM Private CA to write the - // CRL to your bucket. - S3BucketName *string `min:"3" type:"string"` -} - -// String returns the string representation -func (s CrlConfiguration) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CrlConfiguration) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CrlConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CrlConfiguration"} - if s.Enabled == nil { - invalidParams.Add(request.NewErrParamRequired("Enabled")) - } - if s.ExpirationInDays != nil && *s.ExpirationInDays < 1 { - invalidParams.Add(request.NewErrParamMinValue("ExpirationInDays", 1)) - } - if s.S3BucketName != nil && len(*s.S3BucketName) < 3 { - invalidParams.Add(request.NewErrParamMinLen("S3BucketName", 3)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCustomCname sets the CustomCname field's value. -func (s *CrlConfiguration) SetCustomCname(v string) *CrlConfiguration { - s.CustomCname = &v - return s -} - -// SetEnabled sets the Enabled field's value. -func (s *CrlConfiguration) SetEnabled(v bool) *CrlConfiguration { - s.Enabled = &v - return s -} - -// SetExpirationInDays sets the ExpirationInDays field's value. -func (s *CrlConfiguration) SetExpirationInDays(v int64) *CrlConfiguration { - s.ExpirationInDays = &v - return s -} - -// SetS3BucketName sets the S3BucketName field's value. -func (s *CrlConfiguration) SetS3BucketName(v string) *CrlConfiguration { - s.S3BucketName = &v - return s -} - -type DeleteCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must have the following form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // The number of days to make a CA restorable after it has been deleted. This - // can be anywhere from 7 to 30 days, with 30 being the default. - PermanentDeletionTimeInDays *int64 `min:"7" type:"integer"` -} - -// String returns the string representation -func (s DeleteCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.PermanentDeletionTimeInDays != nil && *s.PermanentDeletionTimeInDays < 7 { - invalidParams.Add(request.NewErrParamMinValue("PermanentDeletionTimeInDays", 7)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *DeleteCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *DeleteCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetPermanentDeletionTimeInDays sets the PermanentDeletionTimeInDays field's value. -func (s *DeleteCertificateAuthorityInput) SetPermanentDeletionTimeInDays(v int64) *DeleteCertificateAuthorityInput { - s.PermanentDeletionTimeInDays = &v - return s -} - -type DeleteCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s DeleteCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteCertificateAuthorityOutput) GoString() string { - return s.String() -} - -type DeletePermissionInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Number (ARN) of the private CA that issued the permissions. - // You can find the CA's ARN by calling the ListCertificateAuthorities action. - // This must have the following form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // The AWS service or identity that will have its CA permissions revoked. At - // this time, the only valid service principal is acm.amazonaws.com - // - // Principal is a required field - Principal *string `type:"string" required:"true"` - - // The AWS account that calls this action. - SourceAccount *string `min:"12" type:"string"` -} - -// String returns the string representation -func (s DeletePermissionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeletePermissionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeletePermissionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeletePermissionInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.Principal == nil { - invalidParams.Add(request.NewErrParamRequired("Principal")) - } - if s.SourceAccount != nil && len(*s.SourceAccount) < 12 { - invalidParams.Add(request.NewErrParamMinLen("SourceAccount", 12)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *DeletePermissionInput) SetCertificateAuthorityArn(v string) *DeletePermissionInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetPrincipal sets the Principal field's value. -func (s *DeletePermissionInput) SetPrincipal(v string) *DeletePermissionInput { - s.Principal = &v - return s -} - -// SetSourceAccount sets the SourceAccount field's value. -func (s *DeletePermissionInput) SetSourceAccount(v string) *DeletePermissionInput { - s.SourceAccount = &v - return s -} - -type DeletePermissionOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s DeletePermissionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeletePermissionOutput) GoString() string { - return s.String() -} - -type DescribeCertificateAuthorityAuditReportInput struct { - _ struct{} `type:"structure"` - - // The report ID returned by calling the CreateCertificateAuthorityAuditReport - // action. - // - // AuditReportId is a required field - AuditReportId *string `min:"36" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) of the private CA. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s DescribeCertificateAuthorityAuditReportInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCertificateAuthorityAuditReportInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeCertificateAuthorityAuditReportInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeCertificateAuthorityAuditReportInput"} - if s.AuditReportId == nil { - invalidParams.Add(request.NewErrParamRequired("AuditReportId")) - } - if s.AuditReportId != nil && len(*s.AuditReportId) < 36 { - invalidParams.Add(request.NewErrParamMinLen("AuditReportId", 36)) - } - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAuditReportId sets the AuditReportId field's value. -func (s *DescribeCertificateAuthorityAuditReportInput) SetAuditReportId(v string) *DescribeCertificateAuthorityAuditReportInput { - s.AuditReportId = &v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *DescribeCertificateAuthorityAuditReportInput) SetCertificateAuthorityArn(v string) *DescribeCertificateAuthorityAuditReportInput { - s.CertificateAuthorityArn = &v - return s -} - -type DescribeCertificateAuthorityAuditReportOutput struct { - _ struct{} `type:"structure"` - - // Specifies whether report creation is in progress, has succeeded, or has failed. - AuditReportStatus *string `type:"string" enum:"AuditReportStatus"` - - // The date and time at which the report was created. - CreatedAt *time.Time `type:"timestamp"` - - // Name of the S3 bucket that contains the report. - S3BucketName *string `type:"string"` - - // S3 key that uniquely identifies the report file in your S3 bucket. - S3Key *string `type:"string"` -} - -// String returns the string representation -func (s DescribeCertificateAuthorityAuditReportOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCertificateAuthorityAuditReportOutput) GoString() string { - return s.String() -} - -// SetAuditReportStatus sets the AuditReportStatus field's value. -func (s *DescribeCertificateAuthorityAuditReportOutput) SetAuditReportStatus(v string) *DescribeCertificateAuthorityAuditReportOutput { - s.AuditReportStatus = &v - return s -} - -// SetCreatedAt sets the CreatedAt field's value. -func (s *DescribeCertificateAuthorityAuditReportOutput) SetCreatedAt(v time.Time) *DescribeCertificateAuthorityAuditReportOutput { - s.CreatedAt = &v - return s -} - -// SetS3BucketName sets the S3BucketName field's value. -func (s *DescribeCertificateAuthorityAuditReportOutput) SetS3BucketName(v string) *DescribeCertificateAuthorityAuditReportOutput { - s.S3BucketName = &v - return s -} - -// SetS3Key sets the S3Key field's value. -func (s *DescribeCertificateAuthorityAuditReportOutput) SetS3Key(v string) *DescribeCertificateAuthorityAuditReportOutput { - s.S3Key = &v - return s -} - -type DescribeCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s DescribeCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *DescribeCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *DescribeCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -type DescribeCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` - - // A CertificateAuthority structure that contains information about your private - // CA. - CertificateAuthority *CertificateAuthority `type:"structure"` -} - -// String returns the string representation -func (s DescribeCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCertificateAuthorityOutput) GoString() string { - return s.String() -} - -// SetCertificateAuthority sets the CertificateAuthority field's value. -func (s *DescribeCertificateAuthorityOutput) SetCertificateAuthority(v *CertificateAuthority) *DescribeCertificateAuthorityOutput { - s.CertificateAuthority = v - return s -} - -type GetCertificateAuthorityCertificateInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of your private CA. This is of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s GetCertificateAuthorityCertificateInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateAuthorityCertificateInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetCertificateAuthorityCertificateInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetCertificateAuthorityCertificateInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *GetCertificateAuthorityCertificateInput) SetCertificateAuthorityArn(v string) *GetCertificateAuthorityCertificateInput { - s.CertificateAuthorityArn = &v - return s -} - -type GetCertificateAuthorityCertificateOutput struct { - _ struct{} `type:"structure"` - - // Base64-encoded certificate authority (CA) certificate. - Certificate *string `type:"string"` - - // Base64-encoded certificate chain that includes any intermediate certificates - // and chains up to root on-premises certificate that you used to sign your - // private CA certificate. The chain does not include your private CA certificate. - // If this is a root CA, the value will be null. - CertificateChain *string `type:"string"` -} - -// String returns the string representation -func (s GetCertificateAuthorityCertificateOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateAuthorityCertificateOutput) GoString() string { - return s.String() -} - -// SetCertificate sets the Certificate field's value. -func (s *GetCertificateAuthorityCertificateOutput) SetCertificate(v string) *GetCertificateAuthorityCertificateOutput { - s.Certificate = &v - return s -} - -// SetCertificateChain sets the CertificateChain field's value. -func (s *GetCertificateAuthorityCertificateOutput) SetCertificateChain(v string) *GetCertificateAuthorityCertificateOutput { - s.CertificateChain = &v - return s -} - -type GetCertificateAuthorityCsrInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called the CreateCertificateAuthority - // action. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s GetCertificateAuthorityCsrInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateAuthorityCsrInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetCertificateAuthorityCsrInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetCertificateAuthorityCsrInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *GetCertificateAuthorityCsrInput) SetCertificateAuthorityArn(v string) *GetCertificateAuthorityCsrInput { - s.CertificateAuthorityArn = &v - return s -} - -type GetCertificateAuthorityCsrOutput struct { - _ struct{} `type:"structure"` - - // The base64 PEM-encoded certificate signing request (CSR) for your private - // CA certificate. - Csr *string `type:"string"` -} - -// String returns the string representation -func (s GetCertificateAuthorityCsrOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateAuthorityCsrOutput) GoString() string { - return s.String() -} - -// SetCsr sets the Csr field's value. -func (s *GetCertificateAuthorityCsrOutput) SetCsr(v string) *GetCertificateAuthorityCsrOutput { - s.Csr = &v - return s -} - -type GetCertificateInput struct { - _ struct{} `type:"structure"` - - // The ARN of the issued certificate. The ARN contains the certificate serial - // number and must be in the following form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012/certificate/286535153982981100925020015808220737245 - // - // CertificateArn is a required field - CertificateArn *string `min:"5" type:"string" required:"true"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 . - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s GetCertificateInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetCertificateInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetCertificateInput"} - if s.CertificateArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateArn")) - } - if s.CertificateArn != nil && len(*s.CertificateArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateArn", 5)) - } - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateArn sets the CertificateArn field's value. -func (s *GetCertificateInput) SetCertificateArn(v string) *GetCertificateInput { - s.CertificateArn = &v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *GetCertificateInput) SetCertificateAuthorityArn(v string) *GetCertificateInput { - s.CertificateAuthorityArn = &v - return s -} - -type GetCertificateOutput struct { - _ struct{} `type:"structure"` - - // The base64 PEM-encoded certificate specified by the CertificateArn parameter. - Certificate *string `type:"string"` - - // The base64 PEM-encoded certificate chain that chains up to the on-premises - // root CA certificate that you used to sign your private CA certificate. - CertificateChain *string `type:"string"` -} - -// String returns the string representation -func (s GetCertificateOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetCertificateOutput) GoString() string { - return s.String() -} - -// SetCertificate sets the Certificate field's value. -func (s *GetCertificateOutput) SetCertificate(v string) *GetCertificateOutput { - s.Certificate = &v - return s -} - -// SetCertificateChain sets the CertificateChain field's value. -func (s *GetCertificateOutput) SetCertificateChain(v string) *GetCertificateOutput { - s.CertificateChain = &v - return s -} - -type ImportCertificateAuthorityCertificateInput struct { - _ struct{} `type:"structure"` - - // The PEM-encoded certificate for a private CA. This may be a self-signed certificate - // in the case of a root CA, or it may be signed by another CA that you control. - // - // Certificate is automatically base64 encoded/decoded by the SDK. - // - // Certificate is a required field - Certificate []byte `min:"1" type:"blob" required:"true"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // A PEM-encoded file that contains all of your certificates, other than the - // certificate you're importing, chaining up to your root CA. Your ACM Private - // CA-hosted or on-premises root certificate is the last in the chain, and each - // certificate in the chain signs the one preceding. - // - // This parameter must be supplied when you import a subordinate CA. When you - // import a root CA, there is no chain. - // - // CertificateChain is automatically base64 encoded/decoded by the SDK. - CertificateChain []byte `type:"blob"` -} - -// String returns the string representation -func (s ImportCertificateAuthorityCertificateInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ImportCertificateAuthorityCertificateInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ImportCertificateAuthorityCertificateInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ImportCertificateAuthorityCertificateInput"} - if s.Certificate == nil { - invalidParams.Add(request.NewErrParamRequired("Certificate")) - } - if s.Certificate != nil && len(s.Certificate) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Certificate", 1)) - } - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificate sets the Certificate field's value. -func (s *ImportCertificateAuthorityCertificateInput) SetCertificate(v []byte) *ImportCertificateAuthorityCertificateInput { - s.Certificate = v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *ImportCertificateAuthorityCertificateInput) SetCertificateAuthorityArn(v string) *ImportCertificateAuthorityCertificateInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetCertificateChain sets the CertificateChain field's value. -func (s *ImportCertificateAuthorityCertificateInput) SetCertificateChain(v []byte) *ImportCertificateAuthorityCertificateInput { - s.CertificateChain = v - return s -} - -type ImportCertificateAuthorityCertificateOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s ImportCertificateAuthorityCertificateOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ImportCertificateAuthorityCertificateOutput) GoString() string { - return s.String() -} - -type IssueCertificateInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // The certificate signing request (CSR) for the certificate you want to issue. - // You can use the following OpenSSL command to create the CSR and a 2048 bit - // RSA private key. - // - // openssl req -new -newkey rsa:2048 -days 365 -keyout private/test_cert_priv_key.pem - // -out csr/test_cert_.csr - // - // If you have a configuration file, you can use the following OpenSSL command. - // The usr_cert block in the configuration file contains your X509 version 3 - // extensions. - // - // openssl req -new -config openssl_rsa.cnf -extensions usr_cert -newkey rsa:2048 - // -days -365 -keyout private/test_cert_priv_key.pem -out csr/test_cert_.csr - // - // Csr is automatically base64 encoded/decoded by the SDK. - // - // Csr is a required field - Csr []byte `min:"1" type:"blob" required:"true"` - - // Custom string that can be used to distinguish between calls to the IssueCertificate - // action. Idempotency tokens time out after one hour. Therefore, if you call - // IssueCertificate multiple times with the same idempotency token within 5 - // minutes, ACM Private CA recognizes that you are requesting only one certificate - // and will issue only one. If you change the idempotency token for each call, - // PCA recognizes that you are requesting multiple certificates. - IdempotencyToken *string `min:"1" type:"string"` - - // The name of the algorithm that will be used to sign the certificate to be - // issued. - // - // SigningAlgorithm is a required field - SigningAlgorithm *string `type:"string" required:"true" enum:"SigningAlgorithm"` - - // Specifies a custom configuration template to use when issuing a certificate. - // If this parameter is not provided, ACM Private CA defaults to the EndEntityCertificate/V1 - // template. - // - // The following service-owned TemplateArn values are supported by ACM Private - // CA: - // - // * arn:aws:acm-pca:::template/EndEntityCertificate/V1 - // - // * arn:aws:acm-pca:::template/SubordinateCACertificate_PathLen0/V1 - // - // * arn:aws:acm-pca:::template/SubordinateCACertificate_PathLen1/V1 - // - // * arn:aws:acm-pca:::template/SubordinateCACertificate_PathLen2/V1 - // - // * arn:aws:acm-pca:::template/SubordinateCACertificate_PathLen3/V1 - // - // * arn:aws:acm-pca:::template/RootCACertificate/V1 - // - // For more information, see Using Templates (https://docs.aws.amazon.com/acm-pca/latest/userguide/UsingTemplates.html). - TemplateArn *string `min:"5" type:"string"` - - // The type of the validity period. - // - // Validity is a required field - Validity *Validity `type:"structure" required:"true"` -} - -// String returns the string representation -func (s IssueCertificateInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s IssueCertificateInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *IssueCertificateInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "IssueCertificateInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.Csr == nil { - invalidParams.Add(request.NewErrParamRequired("Csr")) - } - if s.Csr != nil && len(s.Csr) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Csr", 1)) - } - if s.IdempotencyToken != nil && len(*s.IdempotencyToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("IdempotencyToken", 1)) - } - if s.SigningAlgorithm == nil { - invalidParams.Add(request.NewErrParamRequired("SigningAlgorithm")) - } - if s.TemplateArn != nil && len(*s.TemplateArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("TemplateArn", 5)) - } - if s.Validity == nil { - invalidParams.Add(request.NewErrParamRequired("Validity")) - } - if s.Validity != nil { - if err := s.Validity.Validate(); err != nil { - invalidParams.AddNested("Validity", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *IssueCertificateInput) SetCertificateAuthorityArn(v string) *IssueCertificateInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetCsr sets the Csr field's value. -func (s *IssueCertificateInput) SetCsr(v []byte) *IssueCertificateInput { - s.Csr = v - return s -} - -// SetIdempotencyToken sets the IdempotencyToken field's value. -func (s *IssueCertificateInput) SetIdempotencyToken(v string) *IssueCertificateInput { - s.IdempotencyToken = &v - return s -} - -// SetSigningAlgorithm sets the SigningAlgorithm field's value. -func (s *IssueCertificateInput) SetSigningAlgorithm(v string) *IssueCertificateInput { - s.SigningAlgorithm = &v - return s -} - -// SetTemplateArn sets the TemplateArn field's value. -func (s *IssueCertificateInput) SetTemplateArn(v string) *IssueCertificateInput { - s.TemplateArn = &v - return s -} - -// SetValidity sets the Validity field's value. -func (s *IssueCertificateInput) SetValidity(v *Validity) *IssueCertificateInput { - s.Validity = v - return s -} - -type IssueCertificateOutput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the issued certificate and the certificate - // serial number. This is of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012/certificate/286535153982981100925020015808220737245 - CertificateArn *string `min:"5" type:"string"` -} - -// String returns the string representation -func (s IssueCertificateOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s IssueCertificateOutput) GoString() string { - return s.String() -} - -// SetCertificateArn sets the CertificateArn field's value. -func (s *IssueCertificateOutput) SetCertificateArn(v string) *IssueCertificateOutput { - s.CertificateArn = &v - return s -} - -type ListCertificateAuthoritiesInput struct { - _ struct{} `type:"structure"` - - // Use this parameter when paginating results to specify the maximum number - // of items to return in the response on each page. If additional items exist - // beyond the number you specify, the NextToken element is sent in the response. - // Use this NextToken value in a subsequent request to retrieve additional items. - MaxResults *int64 `min:"1" type:"integer"` - - // Use this parameter when paginating results in a subsequent request after - // you receive a response with truncated results. Set it to the value of the - // NextToken parameter from the response you just received. - NextToken *string `min:"1" type:"string"` -} - -// String returns the string representation -func (s ListCertificateAuthoritiesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListCertificateAuthoritiesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListCertificateAuthoritiesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListCertificateAuthoritiesInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListCertificateAuthoritiesInput) SetMaxResults(v int64) *ListCertificateAuthoritiesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListCertificateAuthoritiesInput) SetNextToken(v string) *ListCertificateAuthoritiesInput { - s.NextToken = &v - return s -} - -type ListCertificateAuthoritiesOutput struct { - _ struct{} `type:"structure"` - - // Summary information about each certificate authority you have created. - CertificateAuthorities []*CertificateAuthority `type:"list"` - - // When the list is truncated, this value is present and should be used for - // the NextToken parameter in a subsequent pagination request. - NextToken *string `min:"1" type:"string"` -} - -// String returns the string representation -func (s ListCertificateAuthoritiesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListCertificateAuthoritiesOutput) GoString() string { - return s.String() -} - -// SetCertificateAuthorities sets the CertificateAuthorities field's value. -func (s *ListCertificateAuthoritiesOutput) SetCertificateAuthorities(v []*CertificateAuthority) *ListCertificateAuthoritiesOutput { - s.CertificateAuthorities = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListCertificateAuthoritiesOutput) SetNextToken(v string) *ListCertificateAuthoritiesOutput { - s.NextToken = &v - return s -} - -type ListPermissionsInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Number (ARN) of the private CA to inspect. You can find - // the ARN by calling the ListCertificateAuthorities action. This must be of - // the form: arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // You can get a private CA's ARN by running the ListCertificateAuthorities - // action. - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // When paginating results, use this parameter to specify the maximum number - // of items to return in the response. If additional items exist beyond the - // number you specify, the NextToken element is sent in the response. Use this - // NextToken value in a subsequent request to retrieve additional items. - MaxResults *int64 `min:"1" type:"integer"` - - // When paginating results, use this parameter in a subsequent request after - // you receive a response with truncated results. Set it to the value of NextToken - // from the response you just received. - NextToken *string `min:"1" type:"string"` -} - -// String returns the string representation -func (s ListPermissionsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListPermissionsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListPermissionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListPermissionsInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *ListPermissionsInput) SetCertificateAuthorityArn(v string) *ListPermissionsInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListPermissionsInput) SetMaxResults(v int64) *ListPermissionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListPermissionsInput) SetNextToken(v string) *ListPermissionsInput { - s.NextToken = &v - return s -} - -type ListPermissionsOutput struct { - _ struct{} `type:"structure"` - - // When the list is truncated, this value is present and should be used for - // the NextToken parameter in a subsequent pagination request. - NextToken *string `min:"1" type:"string"` - - // Summary information about each permission assigned by the specified private - // CA, including the action enabled, the policy provided, and the time of creation. - Permissions []*Permission `type:"list"` -} - -// String returns the string representation -func (s ListPermissionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListPermissionsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *ListPermissionsOutput) SetNextToken(v string) *ListPermissionsOutput { - s.NextToken = &v - return s -} - -// SetPermissions sets the Permissions field's value. -func (s *ListPermissionsOutput) SetPermissions(v []*Permission) *ListPermissionsOutput { - s.Permissions = v - return s -} - -type ListTagsInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called the CreateCertificateAuthority - // action. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // Use this parameter when paginating results to specify the maximum number - // of items to return in the response. If additional items exist beyond the - // number you specify, the NextToken element is sent in the response. Use this - // NextToken value in a subsequent request to retrieve additional items. - MaxResults *int64 `min:"1" type:"integer"` - - // Use this parameter when paginating results in a subsequent request after - // you receive a response with truncated results. Set it to the value of NextToken - // from the response you just received. - NextToken *string `min:"1" type:"string"` -} - -// String returns the string representation -func (s ListTagsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListTagsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListTagsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListTagsInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *ListTagsInput) SetCertificateAuthorityArn(v string) *ListTagsInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *ListTagsInput) SetMaxResults(v int64) *ListTagsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *ListTagsInput) SetNextToken(v string) *ListTagsInput { - s.NextToken = &v - return s -} - -type ListTagsOutput struct { - _ struct{} `type:"structure"` - - // When the list is truncated, this value is present and should be used for - // the NextToken parameter in a subsequent pagination request. - NextToken *string `min:"1" type:"string"` - - // The tags associated with your private CA. - Tags []*Tag `min:"1" type:"list"` -} - -// String returns the string representation -func (s ListTagsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ListTagsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *ListTagsOutput) SetNextToken(v string) *ListTagsOutput { - s.NextToken = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *ListTagsOutput) SetTags(v []*Tag) *ListTagsOutput { - s.Tags = v - return s -} - -// Permissions designate which private CA actions can be performed by an AWS -// service or entity. In order for ACM to automatically renew private certificates, -// you must give the ACM service principal all available permissions (IssueCertificate, -// GetCertificate, and ListPermissions). Permissions can be assigned with the -// CreatePermission action, removed with the DeletePermission action, and listed -// with the ListPermissions action. -type Permission struct { - _ struct{} `type:"structure"` - - // The private CA actions that can be performed by the designated AWS service. - Actions []*string `min:"1" type:"list"` - - // The Amazon Resource Number (ARN) of the private CA from which the permission - // was issued. - CertificateAuthorityArn *string `min:"5" type:"string"` - - // The time at which the permission was created. - CreatedAt *time.Time `type:"timestamp"` - - // The name of the policy that is associated with the permission. - Policy *string `type:"string"` - - // The AWS service or entity that holds the permission. At this time, the only - // valid principal is acm.amazonaws.com. - Principal *string `type:"string"` - - // The ID of the account that assigned the permission. - SourceAccount *string `type:"string"` -} - -// String returns the string representation -func (s Permission) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s Permission) GoString() string { - return s.String() -} - -// SetActions sets the Actions field's value. -func (s *Permission) SetActions(v []*string) *Permission { - s.Actions = v - return s -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *Permission) SetCertificateAuthorityArn(v string) *Permission { - s.CertificateAuthorityArn = &v - return s -} - -// SetCreatedAt sets the CreatedAt field's value. -func (s *Permission) SetCreatedAt(v time.Time) *Permission { - s.CreatedAt = &v - return s -} - -// SetPolicy sets the Policy field's value. -func (s *Permission) SetPolicy(v string) *Permission { - s.Policy = &v - return s -} - -// SetPrincipal sets the Principal field's value. -func (s *Permission) SetPrincipal(v string) *Permission { - s.Principal = &v - return s -} - -// SetSourceAccount sets the SourceAccount field's value. -func (s *Permission) SetSourceAccount(v string) *Permission { - s.SourceAccount = &v - return s -} - -type RestoreCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called the CreateCertificateAuthority - // action. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` -} - -// String returns the string representation -func (s RestoreCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RestoreCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *RestoreCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RestoreCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *RestoreCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *RestoreCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -type RestoreCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s RestoreCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RestoreCertificateAuthorityOutput) GoString() string { - return s.String() -} - -// Certificate revocation information used by the CreateCertificateAuthority -// and UpdateCertificateAuthority actions. Your private certificate authority -// (CA) can create and maintain a certificate revocation list (CRL). A CRL contains -// information about certificates revoked by your CA. For more information, -// see RevokeCertificate. -type RevocationConfiguration struct { - _ struct{} `type:"structure"` - - // Configuration of the certificate revocation list (CRL), if any, maintained - // by your private CA. - CrlConfiguration *CrlConfiguration `type:"structure"` -} - -// String returns the string representation -func (s RevocationConfiguration) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RevocationConfiguration) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *RevocationConfiguration) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RevocationConfiguration"} - if s.CrlConfiguration != nil { - if err := s.CrlConfiguration.Validate(); err != nil { - invalidParams.AddNested("CrlConfiguration", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCrlConfiguration sets the CrlConfiguration field's value. -func (s *RevocationConfiguration) SetCrlConfiguration(v *CrlConfiguration) *RevocationConfiguration { - s.CrlConfiguration = v - return s -} - -type RevokeCertificateInput struct { - _ struct{} `type:"structure"` - - // Amazon Resource Name (ARN) of the private CA that issued the certificate - // to be revoked. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // Serial number of the certificate to be revoked. This must be in hexadecimal - // format. You can retrieve the serial number by calling GetCertificate with - // the Amazon Resource Name (ARN) of the certificate you want and the ARN of - // your private CA. The GetCertificate action retrieves the certificate in the - // PEM format. You can use the following OpenSSL command to list the certificate - // in text format and copy the hexadecimal serial number. - // - // openssl x509 -in file_path -text -noout - // - // You can also copy the serial number from the console or use the DescribeCertificate - // (https://docs.aws.amazon.com/acm/latest/APIReference/API_DescribeCertificate.html) - // action in the AWS Certificate Manager API Reference. - // - // CertificateSerial is a required field - CertificateSerial *string `type:"string" required:"true"` - - // Specifies why you revoked the certificate. - // - // RevocationReason is a required field - RevocationReason *string `type:"string" required:"true" enum:"RevocationReason"` -} - -// String returns the string representation -func (s RevokeCertificateInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RevokeCertificateInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *RevokeCertificateInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RevokeCertificateInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.CertificateSerial == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateSerial")) - } - if s.RevocationReason == nil { - invalidParams.Add(request.NewErrParamRequired("RevocationReason")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *RevokeCertificateInput) SetCertificateAuthorityArn(v string) *RevokeCertificateInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetCertificateSerial sets the CertificateSerial field's value. -func (s *RevokeCertificateInput) SetCertificateSerial(v string) *RevokeCertificateInput { - s.CertificateSerial = &v - return s -} - -// SetRevocationReason sets the RevocationReason field's value. -func (s *RevokeCertificateInput) SetRevocationReason(v string) *RevokeCertificateInput { - s.RevocationReason = &v - return s -} - -type RevokeCertificateOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s RevokeCertificateOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RevokeCertificateOutput) GoString() string { - return s.String() -} - -// Tags are labels that you can use to identify and organize your private CAs. -// Each tag consists of a key and an optional value. You can associate up to -// 50 tags with a private CA. To add one or more tags to a private CA, call -// the TagCertificateAuthority action. To remove a tag, call the UntagCertificateAuthority -// action. -type Tag struct { - _ struct{} `type:"structure"` - - // Key (name) of the tag. - // - // Key is a required field - Key *string `min:"1" type:"string" required:"true"` - - // Value of the tag. - Value *string `type:"string"` -} - -// String returns the string representation -func (s Tag) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s Tag) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *Tag) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Tag"} - if s.Key == nil { - invalidParams.Add(request.NewErrParamRequired("Key")) - } - if s.Key != nil && len(*s.Key) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Key", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetKey sets the Key field's value. -func (s *Tag) SetKey(v string) *Tag { - s.Key = &v - return s -} - -// SetValue sets the Value field's value. -func (s *Tag) SetValue(v string) *Tag { - s.Value = &v - return s -} - -type TagCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // List of tags to be associated with the CA. - // - // Tags is a required field - Tags []*Tag `min:"1" type:"list" required:"true"` -} - -// String returns the string representation -func (s TagCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TagCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *TagCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "TagCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.Tags == nil { - invalidParams.Add(request.NewErrParamRequired("Tags")) - } - if s.Tags != nil && len(s.Tags) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) - } - if s.Tags != nil { - for i, v := range s.Tags { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) - } - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *TagCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *TagCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TagCertificateAuthorityInput) SetTags(v []*Tag) *TagCertificateAuthorityInput { - s.Tags = v - return s -} - -type TagCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s TagCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TagCertificateAuthorityOutput) GoString() string { - return s.String() -} - -type UntagCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) that was returned when you called CreateCertificateAuthority. - // This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // List of tags to be removed from the CA. - // - // Tags is a required field - Tags []*Tag `min:"1" type:"list" required:"true"` -} - -// String returns the string representation -func (s UntagCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s UntagCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *UntagCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UntagCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.Tags == nil { - invalidParams.Add(request.NewErrParamRequired("Tags")) - } - if s.Tags != nil && len(s.Tags) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) - } - if s.Tags != nil { - for i, v := range s.Tags { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) - } - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *UntagCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *UntagCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *UntagCertificateAuthorityInput) SetTags(v []*Tag) *UntagCertificateAuthorityInput { - s.Tags = v - return s -} - -type UntagCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s UntagCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s UntagCertificateAuthorityOutput) GoString() string { - return s.String() -} - -type UpdateCertificateAuthorityInput struct { - _ struct{} `type:"structure"` - - // Amazon Resource Name (ARN) of the private CA that issued the certificate - // to be revoked. This must be of the form: - // - // arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012 - // - // CertificateAuthorityArn is a required field - CertificateAuthorityArn *string `min:"5" type:"string" required:"true"` - - // Revocation information for your private CA. - RevocationConfiguration *RevocationConfiguration `type:"structure"` - - // Status of your private CA. - Status *string `type:"string" enum:"CertificateAuthorityStatus"` -} - -// String returns the string representation -func (s UpdateCertificateAuthorityInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s UpdateCertificateAuthorityInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *UpdateCertificateAuthorityInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "UpdateCertificateAuthorityInput"} - if s.CertificateAuthorityArn == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateAuthorityArn")) - } - if s.CertificateAuthorityArn != nil && len(*s.CertificateAuthorityArn) < 5 { - invalidParams.Add(request.NewErrParamMinLen("CertificateAuthorityArn", 5)) - } - if s.RevocationConfiguration != nil { - if err := s.RevocationConfiguration.Validate(); err != nil { - invalidParams.AddNested("RevocationConfiguration", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateAuthorityArn sets the CertificateAuthorityArn field's value. -func (s *UpdateCertificateAuthorityInput) SetCertificateAuthorityArn(v string) *UpdateCertificateAuthorityInput { - s.CertificateAuthorityArn = &v - return s -} - -// SetRevocationConfiguration sets the RevocationConfiguration field's value. -func (s *UpdateCertificateAuthorityInput) SetRevocationConfiguration(v *RevocationConfiguration) *UpdateCertificateAuthorityInput { - s.RevocationConfiguration = v - return s -} - -// SetStatus sets the Status field's value. -func (s *UpdateCertificateAuthorityInput) SetStatus(v string) *UpdateCertificateAuthorityInput { - s.Status = &v - return s -} - -type UpdateCertificateAuthorityOutput struct { - _ struct{} `type:"structure"` -} - -// String returns the string representation -func (s UpdateCertificateAuthorityOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s UpdateCertificateAuthorityOutput) GoString() string { - return s.String() -} - -// Length of time for which the certificate issued by your private certificate -// authority (CA), or by the private CA itself, is valid in days, months, or -// years. You can issue a certificate by calling the IssueCertificate action. -type Validity struct { - _ struct{} `type:"structure"` - - // Specifies whether the Value parameter represents days, months, or years. - // - // Type is a required field - Type *string `type:"string" required:"true" enum:"ValidityPeriodType"` - - // Time period. - // - // Value is a required field - Value *int64 `min:"1" type:"long" required:"true"` -} - -// String returns the string representation -func (s Validity) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s Validity) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *Validity) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "Validity"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) - } - if s.Value == nil { - invalidParams.Add(request.NewErrParamRequired("Value")) - } - if s.Value != nil && *s.Value < 1 { - invalidParams.Add(request.NewErrParamMinValue("Value", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetType sets the Type field's value. -func (s *Validity) SetType(v string) *Validity { - s.Type = &v - return s -} - -// SetValue sets the Value field's value. -func (s *Validity) SetValue(v int64) *Validity { - s.Value = &v - return s -} - -const ( - // ActionTypeIssueCertificate is a ActionType enum value - ActionTypeIssueCertificate = "IssueCertificate" - - // ActionTypeGetCertificate is a ActionType enum value - ActionTypeGetCertificate = "GetCertificate" - - // ActionTypeListPermissions is a ActionType enum value - ActionTypeListPermissions = "ListPermissions" -) - -const ( - // AuditReportResponseFormatJson is a AuditReportResponseFormat enum value - AuditReportResponseFormatJson = "JSON" - - // AuditReportResponseFormatCsv is a AuditReportResponseFormat enum value - AuditReportResponseFormatCsv = "CSV" -) - -const ( - // AuditReportStatusCreating is a AuditReportStatus enum value - AuditReportStatusCreating = "CREATING" - - // AuditReportStatusSuccess is a AuditReportStatus enum value - AuditReportStatusSuccess = "SUCCESS" - - // AuditReportStatusFailed is a AuditReportStatus enum value - AuditReportStatusFailed = "FAILED" -) - -const ( - // CertificateAuthorityStatusCreating is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusCreating = "CREATING" - - // CertificateAuthorityStatusPendingCertificate is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusPendingCertificate = "PENDING_CERTIFICATE" - - // CertificateAuthorityStatusActive is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusActive = "ACTIVE" - - // CertificateAuthorityStatusDeleted is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusDeleted = "DELETED" - - // CertificateAuthorityStatusDisabled is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusDisabled = "DISABLED" - - // CertificateAuthorityStatusExpired is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusExpired = "EXPIRED" - - // CertificateAuthorityStatusFailed is a CertificateAuthorityStatus enum value - CertificateAuthorityStatusFailed = "FAILED" -) - -const ( - // CertificateAuthorityTypeRoot is a CertificateAuthorityType enum value - CertificateAuthorityTypeRoot = "ROOT" - - // CertificateAuthorityTypeSubordinate is a CertificateAuthorityType enum value - CertificateAuthorityTypeSubordinate = "SUBORDINATE" -) - -const ( - // FailureReasonRequestTimedOut is a FailureReason enum value - FailureReasonRequestTimedOut = "REQUEST_TIMED_OUT" - - // FailureReasonUnsupportedAlgorithm is a FailureReason enum value - FailureReasonUnsupportedAlgorithm = "UNSUPPORTED_ALGORITHM" - - // FailureReasonOther is a FailureReason enum value - FailureReasonOther = "OTHER" -) - -const ( - // KeyAlgorithmRsa2048 is a KeyAlgorithm enum value - KeyAlgorithmRsa2048 = "RSA_2048" - - // KeyAlgorithmRsa4096 is a KeyAlgorithm enum value - KeyAlgorithmRsa4096 = "RSA_4096" - - // KeyAlgorithmEcPrime256v1 is a KeyAlgorithm enum value - KeyAlgorithmEcPrime256v1 = "EC_prime256v1" - - // KeyAlgorithmEcSecp384r1 is a KeyAlgorithm enum value - KeyAlgorithmEcSecp384r1 = "EC_secp384r1" -) - -const ( - // RevocationReasonUnspecified is a RevocationReason enum value - RevocationReasonUnspecified = "UNSPECIFIED" - - // RevocationReasonKeyCompromise is a RevocationReason enum value - RevocationReasonKeyCompromise = "KEY_COMPROMISE" - - // RevocationReasonCertificateAuthorityCompromise is a RevocationReason enum value - RevocationReasonCertificateAuthorityCompromise = "CERTIFICATE_AUTHORITY_COMPROMISE" - - // RevocationReasonAffiliationChanged is a RevocationReason enum value - RevocationReasonAffiliationChanged = "AFFILIATION_CHANGED" - - // RevocationReasonSuperseded is a RevocationReason enum value - RevocationReasonSuperseded = "SUPERSEDED" - - // RevocationReasonCessationOfOperation is a RevocationReason enum value - RevocationReasonCessationOfOperation = "CESSATION_OF_OPERATION" - - // RevocationReasonPrivilegeWithdrawn is a RevocationReason enum value - RevocationReasonPrivilegeWithdrawn = "PRIVILEGE_WITHDRAWN" - - // RevocationReasonAACompromise is a RevocationReason enum value - RevocationReasonAACompromise = "A_A_COMPROMISE" -) - -const ( - // SigningAlgorithmSha256withecdsa is a SigningAlgorithm enum value - SigningAlgorithmSha256withecdsa = "SHA256WITHECDSA" - - // SigningAlgorithmSha384withecdsa is a SigningAlgorithm enum value - SigningAlgorithmSha384withecdsa = "SHA384WITHECDSA" - - // SigningAlgorithmSha512withecdsa is a SigningAlgorithm enum value - SigningAlgorithmSha512withecdsa = "SHA512WITHECDSA" - - // SigningAlgorithmSha256withrsa is a SigningAlgorithm enum value - SigningAlgorithmSha256withrsa = "SHA256WITHRSA" - - // SigningAlgorithmSha384withrsa is a SigningAlgorithm enum value - SigningAlgorithmSha384withrsa = "SHA384WITHRSA" - - // SigningAlgorithmSha512withrsa is a SigningAlgorithm enum value - SigningAlgorithmSha512withrsa = "SHA512WITHRSA" -) - -const ( - // ValidityPeriodTypeEndDate is a ValidityPeriodType enum value - ValidityPeriodTypeEndDate = "END_DATE" - - // ValidityPeriodTypeAbsolute is a ValidityPeriodType enum value - ValidityPeriodTypeAbsolute = "ABSOLUTE" - - // ValidityPeriodTypeDays is a ValidityPeriodType enum value - ValidityPeriodTypeDays = "DAYS" - - // ValidityPeriodTypeMonths is a ValidityPeriodType enum value - ValidityPeriodTypeMonths = "MONTHS" - - // ValidityPeriodTypeYears is a ValidityPeriodType enum value - ValidityPeriodTypeYears = "YEARS" -) diff --git a/vendor/github.com/aws/aws-sdk-go/service/acmpca/doc.go b/vendor/github.com/aws/aws-sdk-go/service/acmpca/doc.go deleted file mode 100644 index ca360e0e4..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/acmpca/doc.go +++ /dev/null @@ -1,40 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -// Package acmpca provides the client and types for making API -// requests to AWS Certificate Manager Private Certificate Authority. -// -// This is the ACM Private CA API Reference. It provides descriptions, syntax, -// and usage examples for each of the actions and data types involved in creating -// and managing private certificate authorities (CA) for your organization. -// -// The documentation for each action shows the Query API request parameters -// and the XML response. Alternatively, you can use one of the AWS SDKs to access -// an API that's tailored to the programming language or platform that you're -// using. For more information, see AWS SDKs (https://aws.amazon.com/tools/#SDKs). -// -// Each ACM Private CA API action has a throttling limit which determines the -// number of times the action can be called per second. For more information, -// see API Rate Limits in ACM Private CA (https://docs.aws.amazon.com/acm-pca/latest/userguide/PcaLimits.html#PcaLimits-api) -// in the ACM Private CA user guide. -// -// See https://docs.aws.amazon.com/goto/WebAPI/acm-pca-2017-08-22 for more information on this service. -// -// See acmpca package documentation for more information. -// https://docs.aws.amazon.com/sdk-for-go/api/service/acmpca/ -// -// Using the Client -// -// To contact AWS Certificate Manager Private Certificate Authority with the SDK use the New function to create -// a new service client. With that client you can make API requests to the service. -// These clients are safe to use concurrently. -// -// See the SDK's documentation for more information on how to use the SDK. -// https://docs.aws.amazon.com/sdk-for-go/api/ -// -// See aws.Config documentation for more information on configuring SDK clients. -// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config -// -// See the AWS Certificate Manager Private Certificate Authority client ACMPCA for more -// information on creating client for this service. -// https://docs.aws.amazon.com/sdk-for-go/api/service/acmpca/#New -package acmpca diff --git a/vendor/github.com/aws/aws-sdk-go/service/acmpca/errors.go b/vendor/github.com/aws/aws-sdk-go/service/acmpca/errors.go deleted file mode 100644 index c9095bbe2..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/acmpca/errors.go +++ /dev/null @@ -1,122 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -package acmpca - -const ( - - // ErrCodeCertificateMismatchException for service response error code - // "CertificateMismatchException". - // - // The certificate authority certificate you are importing does not comply with - // conditions specified in the certificate that signed it. - ErrCodeCertificateMismatchException = "CertificateMismatchException" - - // ErrCodeConcurrentModificationException for service response error code - // "ConcurrentModificationException". - // - // A previous update to your private CA is still ongoing. - ErrCodeConcurrentModificationException = "ConcurrentModificationException" - - // ErrCodeInvalidArgsException for service response error code - // "InvalidArgsException". - // - // One or more of the specified arguments was not valid. - ErrCodeInvalidArgsException = "InvalidArgsException" - - // ErrCodeInvalidArnException for service response error code - // "InvalidArnException". - // - // The requested Amazon Resource Name (ARN) does not refer to an existing resource. - ErrCodeInvalidArnException = "InvalidArnException" - - // ErrCodeInvalidNextTokenException for service response error code - // "InvalidNextTokenException". - // - // The token specified in the NextToken argument is not valid. Use the token - // returned from your previous call to ListCertificateAuthorities. - ErrCodeInvalidNextTokenException = "InvalidNextTokenException" - - // ErrCodeInvalidPolicyException for service response error code - // "InvalidPolicyException". - // - // The S3 bucket policy is not valid. The policy must give ACM Private CA rights - // to read from and write to the bucket and find the bucket location. - ErrCodeInvalidPolicyException = "InvalidPolicyException" - - // ErrCodeInvalidRequestException for service response error code - // "InvalidRequestException". - // - // The request action cannot be performed or is prohibited. - ErrCodeInvalidRequestException = "InvalidRequestException" - - // ErrCodeInvalidStateException for service response error code - // "InvalidStateException". - // - // The private CA is in a state during which a report or certificate cannot - // be generated. - ErrCodeInvalidStateException = "InvalidStateException" - - // ErrCodeInvalidTagException for service response error code - // "InvalidTagException". - // - // The tag associated with the CA is not valid. The invalid argument is contained - // in the message field. - ErrCodeInvalidTagException = "InvalidTagException" - - // ErrCodeLimitExceededException for service response error code - // "LimitExceededException". - // - // An ACM Private CA limit has been exceeded. See the exception message returned - // to determine the limit that was exceeded. - ErrCodeLimitExceededException = "LimitExceededException" - - // ErrCodeMalformedCSRException for service response error code - // "MalformedCSRException". - // - // The certificate signing request is invalid. - ErrCodeMalformedCSRException = "MalformedCSRException" - - // ErrCodeMalformedCertificateException for service response error code - // "MalformedCertificateException". - // - // One or more fields in the certificate are invalid. - ErrCodeMalformedCertificateException = "MalformedCertificateException" - - // ErrCodePermissionAlreadyExistsException for service response error code - // "PermissionAlreadyExistsException". - // - // The designated permission has already been given to the user. - ErrCodePermissionAlreadyExistsException = "PermissionAlreadyExistsException" - - // ErrCodeRequestAlreadyProcessedException for service response error code - // "RequestAlreadyProcessedException". - // - // Your request has already been completed. - ErrCodeRequestAlreadyProcessedException = "RequestAlreadyProcessedException" - - // ErrCodeRequestFailedException for service response error code - // "RequestFailedException". - // - // The request has failed for an unspecified reason. - ErrCodeRequestFailedException = "RequestFailedException" - - // ErrCodeRequestInProgressException for service response error code - // "RequestInProgressException". - // - // Your request is already in progress. - ErrCodeRequestInProgressException = "RequestInProgressException" - - // ErrCodeResourceNotFoundException for service response error code - // "ResourceNotFoundException". - // - // A resource such as a private CA, S3 bucket, certificate, or audit report - // cannot be found. - ErrCodeResourceNotFoundException = "ResourceNotFoundException" - - // ErrCodeTooManyTagsException for service response error code - // "TooManyTagsException". - // - // You can associate up to 50 tags with a private CA. Exception information - // is contained in the exception message field. - ErrCodeTooManyTagsException = "TooManyTagsException" -) diff --git a/vendor/github.com/aws/aws-sdk-go/service/acmpca/service.go b/vendor/github.com/aws/aws-sdk-go/service/acmpca/service.go deleted file mode 100644 index 6c231c1d7..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/acmpca/service.go +++ /dev/null @@ -1,97 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -package acmpca - -import ( - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/client" - "github.com/aws/aws-sdk-go/aws/client/metadata" - "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/aws/signer/v4" - "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" -) - -// ACMPCA provides the API operation methods for making requests to -// AWS Certificate Manager Private Certificate Authority. See this package's package overview docs -// for details on the service. -// -// ACMPCA methods are safe to use concurrently. It is not safe to -// modify mutate any of the struct's properties though. -type ACMPCA struct { - *client.Client -} - -// Used for custom client initialization logic -var initClient func(*client.Client) - -// Used for custom request initialization logic -var initRequest func(*request.Request) - -// Service information constants -const ( - ServiceName = "acm-pca" // Name of service. - EndpointsID = ServiceName // ID to lookup a service endpoint with. - ServiceID = "ACM PCA" // ServiceID is a unique identifer of a specific service. -) - -// New creates a new instance of the ACMPCA client with a session. -// If additional configuration is needed for the client instance use the optional -// aws.Config parameter to add your extra config. -// -// Example: -// // Create a ACMPCA client from just a session. -// svc := acmpca.New(mySession) -// -// // Create a ACMPCA client with additional configuration -// svc := acmpca.New(mySession, aws.NewConfig().WithRegion("us-west-2")) -func New(p client.ConfigProvider, cfgs ...*aws.Config) *ACMPCA { - c := p.ClientConfig(EndpointsID, cfgs...) - return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) -} - -// newClient creates, initializes and returns a new service client instance. -func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *ACMPCA { - svc := &ACMPCA{ - Client: client.New( - cfg, - metadata.ClientInfo{ - ServiceName: ServiceName, - ServiceID: ServiceID, - SigningName: signingName, - SigningRegion: signingRegion, - Endpoint: endpoint, - APIVersion: "2017-08-22", - JSONVersion: "1.1", - TargetPrefix: "ACMPrivateCA", - }, - handlers, - ), - } - - // Handlers - svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler) - svc.Handlers.Build.PushBackNamed(jsonrpc.BuildHandler) - svc.Handlers.Unmarshal.PushBackNamed(jsonrpc.UnmarshalHandler) - svc.Handlers.UnmarshalMeta.PushBackNamed(jsonrpc.UnmarshalMetaHandler) - svc.Handlers.UnmarshalError.PushBackNamed(jsonrpc.UnmarshalErrorHandler) - - // Run custom client initialization if present - if initClient != nil { - initClient(svc.Client) - } - - return svc -} - -// newRequest creates a new request for a ACMPCA operation and runs any -// custom request initialization. -func (c *ACMPCA) newRequest(op *request.Operation, params, data interface{}) *request.Request { - req := c.NewRequest(op, params, data) - - // Run custom request initialization if present - if initRequest != nil { - initRequest(req) - } - - return req -} diff --git a/vendor/github.com/aws/aws-sdk-go/service/acmpca/waiters.go b/vendor/github.com/aws/aws-sdk-go/service/acmpca/waiters.go deleted file mode 100644 index 3c4a76336..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/acmpca/waiters.go +++ /dev/null @@ -1,163 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -package acmpca - -import ( - "time" - - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/request" -) - -// WaitUntilAuditReportCreated uses the ACM-PCA API operation -// DescribeCertificateAuthorityAuditReport to wait for a condition to be met before returning. -// If the condition is not met within the max attempt window, an error will -// be returned. -func (c *ACMPCA) WaitUntilAuditReportCreated(input *DescribeCertificateAuthorityAuditReportInput) error { - return c.WaitUntilAuditReportCreatedWithContext(aws.BackgroundContext(), input) -} - -// WaitUntilAuditReportCreatedWithContext is an extended version of WaitUntilAuditReportCreated. -// With the support for passing in a context and options to configure the -// Waiter and the underlying request options. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) WaitUntilAuditReportCreatedWithContext(ctx aws.Context, input *DescribeCertificateAuthorityAuditReportInput, opts ...request.WaiterOption) error { - w := request.Waiter{ - Name: "WaitUntilAuditReportCreated", - MaxAttempts: 60, - Delay: request.ConstantWaiterDelay(3 * time.Second), - Acceptors: []request.WaiterAcceptor{ - { - State: request.SuccessWaiterState, - Matcher: request.PathWaiterMatch, Argument: "AuditReportStatus", - Expected: "SUCCESS", - }, - { - State: request.FailureWaiterState, - Matcher: request.PathWaiterMatch, Argument: "AuditReportStatus", - Expected: "FAILED", - }, - }, - Logger: c.Config.Logger, - NewRequest: func(opts []request.Option) (*request.Request, error) { - var inCpy *DescribeCertificateAuthorityAuditReportInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeCertificateAuthorityAuditReportRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - w.ApplyOptions(opts...) - - return w.WaitWithContext(ctx) -} - -// WaitUntilCertificateAuthorityCSRCreated uses the ACM-PCA API operation -// GetCertificateAuthorityCsr to wait for a condition to be met before returning. -// If the condition is not met within the max attempt window, an error will -// be returned. -func (c *ACMPCA) WaitUntilCertificateAuthorityCSRCreated(input *GetCertificateAuthorityCsrInput) error { - return c.WaitUntilCertificateAuthorityCSRCreatedWithContext(aws.BackgroundContext(), input) -} - -// WaitUntilCertificateAuthorityCSRCreatedWithContext is an extended version of WaitUntilCertificateAuthorityCSRCreated. -// With the support for passing in a context and options to configure the -// Waiter and the underlying request options. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) WaitUntilCertificateAuthorityCSRCreatedWithContext(ctx aws.Context, input *GetCertificateAuthorityCsrInput, opts ...request.WaiterOption) error { - w := request.Waiter{ - Name: "WaitUntilCertificateAuthorityCSRCreated", - MaxAttempts: 60, - Delay: request.ConstantWaiterDelay(3 * time.Second), - Acceptors: []request.WaiterAcceptor{ - { - State: request.SuccessWaiterState, - Matcher: request.StatusWaiterMatch, - Expected: 200, - }, - { - State: request.RetryWaiterState, - Matcher: request.ErrorWaiterMatch, - Expected: "RequestInProgressException", - }, - }, - Logger: c.Config.Logger, - NewRequest: func(opts []request.Option) (*request.Request, error) { - var inCpy *GetCertificateAuthorityCsrInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetCertificateAuthorityCsrRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - w.ApplyOptions(opts...) - - return w.WaitWithContext(ctx) -} - -// WaitUntilCertificateIssued uses the ACM-PCA API operation -// GetCertificate to wait for a condition to be met before returning. -// If the condition is not met within the max attempt window, an error will -// be returned. -func (c *ACMPCA) WaitUntilCertificateIssued(input *GetCertificateInput) error { - return c.WaitUntilCertificateIssuedWithContext(aws.BackgroundContext(), input) -} - -// WaitUntilCertificateIssuedWithContext is an extended version of WaitUntilCertificateIssued. -// With the support for passing in a context and options to configure the -// Waiter and the underlying request options. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *ACMPCA) WaitUntilCertificateIssuedWithContext(ctx aws.Context, input *GetCertificateInput, opts ...request.WaiterOption) error { - w := request.Waiter{ - Name: "WaitUntilCertificateIssued", - MaxAttempts: 60, - Delay: request.ConstantWaiterDelay(3 * time.Second), - Acceptors: []request.WaiterAcceptor{ - { - State: request.SuccessWaiterState, - Matcher: request.StatusWaiterMatch, - Expected: 200, - }, - { - State: request.RetryWaiterState, - Matcher: request.ErrorWaiterMatch, - Expected: "RequestInProgressException", - }, - }, - Logger: c.Config.Logger, - NewRequest: func(opts []request.Option) (*request.Request, error) { - var inCpy *GetCertificateInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetCertificateRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - w.ApplyOptions(opts...) - - return w.WaitWithContext(ctx) -} diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go index 123276e92..292fd5c50 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/api.go @@ -18,7 +18,7 @@ const opAcceptReservedInstancesExchangeQuote = "AcceptReservedInstancesExchangeQ // AcceptReservedInstancesExchangeQuoteRequest generates a "aws/request.Request" representing the // client's request for the AcceptReservedInstancesExchangeQuote operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -88,90 +88,12 @@ func (c *EC2) AcceptReservedInstancesExchangeQuoteWithContext(ctx aws.Context, i return out, req.Send() } -const opAcceptTransitGatewayVpcAttachment = "AcceptTransitGatewayVpcAttachment" - -// AcceptTransitGatewayVpcAttachmentRequest generates a "aws/request.Request" representing the -// client's request for the AcceptTransitGatewayVpcAttachment operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See AcceptTransitGatewayVpcAttachment for more information on using the AcceptTransitGatewayVpcAttachment -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the AcceptTransitGatewayVpcAttachmentRequest method. -// req, resp := client.AcceptTransitGatewayVpcAttachmentRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AcceptTransitGatewayVpcAttachment -func (c *EC2) AcceptTransitGatewayVpcAttachmentRequest(input *AcceptTransitGatewayVpcAttachmentInput) (req *request.Request, output *AcceptTransitGatewayVpcAttachmentOutput) { - op := &request.Operation{ - Name: opAcceptTransitGatewayVpcAttachment, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &AcceptTransitGatewayVpcAttachmentInput{} - } - - output = &AcceptTransitGatewayVpcAttachmentOutput{} - req = c.newRequest(op, input, output) - return -} - -// AcceptTransitGatewayVpcAttachment API operation for Amazon Elastic Compute Cloud. -// -// Accepts a request to attach a VPC to a transit gateway. -// -// The VPC attachment must be in the pendingAcceptance state. Use DescribeTransitGatewayVpcAttachments -// to view your pending VPC attachment requests. Use RejectTransitGatewayVpcAttachment -// to reject a VPC attachment request. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation AcceptTransitGatewayVpcAttachment for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AcceptTransitGatewayVpcAttachment -func (c *EC2) AcceptTransitGatewayVpcAttachment(input *AcceptTransitGatewayVpcAttachmentInput) (*AcceptTransitGatewayVpcAttachmentOutput, error) { - req, out := c.AcceptTransitGatewayVpcAttachmentRequest(input) - return out, req.Send() -} - -// AcceptTransitGatewayVpcAttachmentWithContext is the same as AcceptTransitGatewayVpcAttachment with the addition of -// the ability to pass a context and additional request options. -// -// See AcceptTransitGatewayVpcAttachment for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) AcceptTransitGatewayVpcAttachmentWithContext(ctx aws.Context, input *AcceptTransitGatewayVpcAttachmentInput, opts ...request.Option) (*AcceptTransitGatewayVpcAttachmentOutput, error) { - req, out := c.AcceptTransitGatewayVpcAttachmentRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAcceptVpcEndpointConnections = "AcceptVpcEndpointConnections" // AcceptVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the AcceptVpcEndpointConnections operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -246,7 +168,7 @@ const opAcceptVpcPeeringConnection = "AcceptVpcPeeringConnection" // AcceptVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the AcceptVpcPeeringConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -290,8 +212,8 @@ func (c *EC2) AcceptVpcPeeringConnectionRequest(input *AcceptVpcPeeringConnectio // of the peer VPC. Use DescribeVpcPeeringConnections to view your outstanding // VPC peering connection requests. // -// For an inter-Region VPC peering connection request, you must accept the VPC -// peering connection in the Region of the accepter VPC. +// For an inter-region VPC peering connection request, you must accept the VPC +// peering connection in the region of the accepter VPC. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -321,101 +243,12 @@ func (c *EC2) AcceptVpcPeeringConnectionWithContext(ctx aws.Context, input *Acce return out, req.Send() } -const opAdvertiseByoipCidr = "AdvertiseByoipCidr" - -// AdvertiseByoipCidrRequest generates a "aws/request.Request" representing the -// client's request for the AdvertiseByoipCidr operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See AdvertiseByoipCidr for more information on using the AdvertiseByoipCidr -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the AdvertiseByoipCidrRequest method. -// req, resp := client.AdvertiseByoipCidrRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AdvertiseByoipCidr -func (c *EC2) AdvertiseByoipCidrRequest(input *AdvertiseByoipCidrInput) (req *request.Request, output *AdvertiseByoipCidrOutput) { - op := &request.Operation{ - Name: opAdvertiseByoipCidr, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &AdvertiseByoipCidrInput{} - } - - output = &AdvertiseByoipCidrOutput{} - req = c.newRequest(op, input, output) - return -} - -// AdvertiseByoipCidr API operation for Amazon Elastic Compute Cloud. -// -// Advertises an IPv4 address range that is provisioned for use with your AWS -// resources through bring your own IP addresses (BYOIP). -// -// You can perform this operation at most once every 10 seconds, even if you -// specify different address ranges each time. -// -// We recommend that you stop advertising the BYOIP CIDR from other locations -// when you advertise it from AWS. To minimize down time, you can configure -// your AWS resources to use an address from a BYOIP CIDR before it is advertised, -// and then simultaneously stop advertising it from the current location and -// start advertising it through AWS. -// -// It can take a few minutes before traffic to the specified addresses starts -// routing to AWS because of BGP propagation delays. -// -// To stop advertising the BYOIP CIDR, use WithdrawByoipCidr. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation AdvertiseByoipCidr for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AdvertiseByoipCidr -func (c *EC2) AdvertiseByoipCidr(input *AdvertiseByoipCidrInput) (*AdvertiseByoipCidrOutput, error) { - req, out := c.AdvertiseByoipCidrRequest(input) - return out, req.Send() -} - -// AdvertiseByoipCidrWithContext is the same as AdvertiseByoipCidr with the addition of -// the ability to pass a context and additional request options. -// -// See AdvertiseByoipCidr for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) AdvertiseByoipCidrWithContext(ctx aws.Context, input *AdvertiseByoipCidrInput, opts ...request.Option) (*AdvertiseByoipCidrOutput, error) { - req, out := c.AdvertiseByoipCidrRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAllocateAddress = "AllocateAddress" // AllocateAddressRequest generates a "aws/request.Request" representing the // client's request for the AllocateAddress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -459,13 +292,6 @@ func (c *EC2) AllocateAddressRequest(input *AllocateAddressInput) (req *request. // After you release an Elastic IP address, it is released to the IP address // pool and can be allocated to a different AWS account. // -// You can allocate an Elastic IP address from an address pool owned by AWS -// or from an address pool created from a public IPv4 address range that you -// have brought to AWS for use with your AWS resources using bring your own -// IP addresses (BYOIP). For more information, see Bring Your Own IP Addresses -// (BYOIP) (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html) -// in the Amazon Elastic Compute Cloud User Guide. -// // [EC2-VPC] If you release an Elastic IP address, you might be able to recover // it. You cannot recover an Elastic IP address that you released after it is // allocated to another AWS account. You cannot recover an Elastic IP address @@ -474,9 +300,9 @@ func (c *EC2) AllocateAddressRequest(input *AllocateAddressInput) (req *request. // // An Elastic IP address is for use either in the EC2-Classic platform or in // a VPC. By default, you can allocate 5 Elastic IP addresses for EC2-Classic -// per Region and 5 Elastic IP addresses for EC2-VPC per Region. +// per region and 5 Elastic IP addresses for EC2-VPC per region. // -// For more information, see Elastic IP Addresses (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) +// For more information, see Elastic IP Addresses (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -512,7 +338,7 @@ const opAllocateHosts = "AllocateHosts" // AllocateHostsRequest generates a "aws/request.Request" representing the // client's request for the AllocateHosts operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -582,88 +408,12 @@ func (c *EC2) AllocateHostsWithContext(ctx aws.Context, input *AllocateHostsInpu return out, req.Send() } -const opApplySecurityGroupsToClientVpnTargetNetwork = "ApplySecurityGroupsToClientVpnTargetNetwork" - -// ApplySecurityGroupsToClientVpnTargetNetworkRequest generates a "aws/request.Request" representing the -// client's request for the ApplySecurityGroupsToClientVpnTargetNetwork operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ApplySecurityGroupsToClientVpnTargetNetwork for more information on using the ApplySecurityGroupsToClientVpnTargetNetwork -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ApplySecurityGroupsToClientVpnTargetNetworkRequest method. -// req, resp := client.ApplySecurityGroupsToClientVpnTargetNetworkRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ApplySecurityGroupsToClientVpnTargetNetwork -func (c *EC2) ApplySecurityGroupsToClientVpnTargetNetworkRequest(input *ApplySecurityGroupsToClientVpnTargetNetworkInput) (req *request.Request, output *ApplySecurityGroupsToClientVpnTargetNetworkOutput) { - op := &request.Operation{ - Name: opApplySecurityGroupsToClientVpnTargetNetwork, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ApplySecurityGroupsToClientVpnTargetNetworkInput{} - } - - output = &ApplySecurityGroupsToClientVpnTargetNetworkOutput{} - req = c.newRequest(op, input, output) - return -} - -// ApplySecurityGroupsToClientVpnTargetNetwork API operation for Amazon Elastic Compute Cloud. -// -// Applies a security group to the association between the target network and -// the Client VPN endpoint. This action replaces the existing security groups -// with the specified security groups. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ApplySecurityGroupsToClientVpnTargetNetwork for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ApplySecurityGroupsToClientVpnTargetNetwork -func (c *EC2) ApplySecurityGroupsToClientVpnTargetNetwork(input *ApplySecurityGroupsToClientVpnTargetNetworkInput) (*ApplySecurityGroupsToClientVpnTargetNetworkOutput, error) { - req, out := c.ApplySecurityGroupsToClientVpnTargetNetworkRequest(input) - return out, req.Send() -} - -// ApplySecurityGroupsToClientVpnTargetNetworkWithContext is the same as ApplySecurityGroupsToClientVpnTargetNetwork with the addition of -// the ability to pass a context and additional request options. -// -// See ApplySecurityGroupsToClientVpnTargetNetwork for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ApplySecurityGroupsToClientVpnTargetNetworkWithContext(ctx aws.Context, input *ApplySecurityGroupsToClientVpnTargetNetworkInput, opts ...request.Option) (*ApplySecurityGroupsToClientVpnTargetNetworkOutput, error) { - req, out := c.ApplySecurityGroupsToClientVpnTargetNetworkRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAssignIpv6Addresses = "AssignIpv6Addresses" // AssignIpv6AddressesRequest generates a "aws/request.Request" representing the // client's request for the AssignIpv6Addresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -708,7 +458,7 @@ func (c *EC2) AssignIpv6AddressesRequest(input *AssignIpv6AddressesInput) (req * // CIDR block range. You can assign as many IPv6 addresses to a network interface // as you can assign private IPv4 addresses, and the limit varies per instance // type. For information, see IP Addresses Per Network Interface Per Instance -// Type (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#AvailableIpPerENI) +// Type (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#AvailableIpPerENI) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -744,7 +494,7 @@ const opAssignPrivateIpAddresses = "AssignPrivateIpAddresses" // AssignPrivateIpAddressesRequest generates a "aws/request.Request" representing the // client's request for the AssignPrivateIpAddresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -778,29 +528,24 @@ func (c *EC2) AssignPrivateIpAddressesRequest(input *AssignPrivateIpAddressesInp output = &AssignPrivateIpAddressesOutput{} req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // AssignPrivateIpAddresses API operation for Amazon Elastic Compute Cloud. // // Assigns one or more secondary private IP addresses to the specified network -// interface. -// -// You can specify one or more specific secondary IP addresses, or you can specify -// the number of secondary IP addresses to be automatically assigned within -// the subnet's CIDR block range. The number of secondary IP addresses that -// you can assign to an instance varies by instance type. For information about -// instance types, see Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) +// interface. You can specify one or more specific secondary IP addresses, or +// you can specify the number of secondary IP addresses to be automatically +// assigned within the subnet's CIDR block range. The number of secondary IP +// addresses that you can assign to an instance varies by instance type. For +// information about instance types, see Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) // in the Amazon Elastic Compute Cloud User Guide. For more information about -// Elastic IP addresses, see Elastic IP Addresses (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) +// Elastic IP addresses, see Elastic IP Addresses (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) // in the Amazon Elastic Compute Cloud User Guide. // -// When you move a secondary private IP address to another network interface, -// any Elastic IP address that is associated with the IP address is also moved. -// -// Remapping an IP address is an asynchronous operation. When you move an IP -// address from one network interface to another, check network/interfaces/macs/mac/local-ipv4s -// in the instance metadata to confirm that the remapping is complete. +// AssignPrivateIpAddresses is available only in EC2-VPC. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -835,7 +580,7 @@ const opAssociateAddress = "AssociateAddress" // AssociateAddressRequest generates a "aws/request.Request" representing the // client's request for the AssociateAddress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -878,7 +623,7 @@ func (c *EC2) AssociateAddressRequest(input *AssociateAddressInput) (req *reques // Before you can use an Elastic IP address, you must allocate it to your account. // // An Elastic IP address is for use in either the EC2-Classic platform or in -// a VPC. For more information, see Elastic IP Addresses (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) +// a VPC. For more information, see Elastic IP Addresses (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) // in the Amazon Elastic Compute Cloud User Guide. // // [EC2-Classic, VPC in an EC2-VPC-only account] If the Elastic IP address is @@ -928,90 +673,12 @@ func (c *EC2) AssociateAddressWithContext(ctx aws.Context, input *AssociateAddre return out, req.Send() } -const opAssociateClientVpnTargetNetwork = "AssociateClientVpnTargetNetwork" - -// AssociateClientVpnTargetNetworkRequest generates a "aws/request.Request" representing the -// client's request for the AssociateClientVpnTargetNetwork operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See AssociateClientVpnTargetNetwork for more information on using the AssociateClientVpnTargetNetwork -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the AssociateClientVpnTargetNetworkRequest method. -// req, resp := client.AssociateClientVpnTargetNetworkRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AssociateClientVpnTargetNetwork -func (c *EC2) AssociateClientVpnTargetNetworkRequest(input *AssociateClientVpnTargetNetworkInput) (req *request.Request, output *AssociateClientVpnTargetNetworkOutput) { - op := &request.Operation{ - Name: opAssociateClientVpnTargetNetwork, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &AssociateClientVpnTargetNetworkInput{} - } - - output = &AssociateClientVpnTargetNetworkOutput{} - req = c.newRequest(op, input, output) - return -} - -// AssociateClientVpnTargetNetwork API operation for Amazon Elastic Compute Cloud. -// -// Associates a target network with a Client VPN endpoint. A target network -// is a subnet in a VPC. You can associate multiple subnets from the same VPC -// with a Client VPN endpoint. You can associate only one subnet in each Availability -// Zone. We recommend that you associate at least two subnets to provide Availability -// Zone redundancy. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation AssociateClientVpnTargetNetwork for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AssociateClientVpnTargetNetwork -func (c *EC2) AssociateClientVpnTargetNetwork(input *AssociateClientVpnTargetNetworkInput) (*AssociateClientVpnTargetNetworkOutput, error) { - req, out := c.AssociateClientVpnTargetNetworkRequest(input) - return out, req.Send() -} - -// AssociateClientVpnTargetNetworkWithContext is the same as AssociateClientVpnTargetNetwork with the addition of -// the ability to pass a context and additional request options. -// -// See AssociateClientVpnTargetNetwork for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) AssociateClientVpnTargetNetworkWithContext(ctx aws.Context, input *AssociateClientVpnTargetNetworkInput, opts ...request.Option) (*AssociateClientVpnTargetNetworkOutput, error) { - req, out := c.AssociateClientVpnTargetNetworkRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAssociateDhcpOptions = "AssociateDhcpOptions" // AssociateDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the AssociateDhcpOptions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1045,7 +712,8 @@ func (c *EC2) AssociateDhcpOptionsRequest(input *AssociateDhcpOptionsInput) (req output = &AssociateDhcpOptionsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -1061,7 +729,7 @@ func (c *EC2) AssociateDhcpOptionsRequest(input *AssociateDhcpOptionsInput) (req // its DHCP lease. You can explicitly renew the lease using the operating system // on the instance. // -// For more information, see DHCP Options Sets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_DHCP_Options.html) +// For more information, see DHCP Options Sets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_DHCP_Options.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -1097,7 +765,7 @@ const opAssociateIamInstanceProfile = "AssociateIamInstanceProfile" // AssociateIamInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the AssociateIamInstanceProfile operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1172,7 +840,7 @@ const opAssociateRouteTable = "AssociateRouteTable" // AssociateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the AssociateRouteTable operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1217,7 +885,7 @@ func (c *EC2) AssociateRouteTableRequest(input *AssociateRouteTableInput) (req * // an association ID, which you need in order to disassociate the route table // from the subnet later. A route table can be associated with multiple subnets. // -// For more information, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// For more information, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -1253,7 +921,7 @@ const opAssociateSubnetCidrBlock = "AssociateSubnetCidrBlock" // AssociateSubnetCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the AssociateSubnetCidrBlock operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1324,87 +992,12 @@ func (c *EC2) AssociateSubnetCidrBlockWithContext(ctx aws.Context, input *Associ return out, req.Send() } -const opAssociateTransitGatewayRouteTable = "AssociateTransitGatewayRouteTable" - -// AssociateTransitGatewayRouteTableRequest generates a "aws/request.Request" representing the -// client's request for the AssociateTransitGatewayRouteTable operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See AssociateTransitGatewayRouteTable for more information on using the AssociateTransitGatewayRouteTable -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the AssociateTransitGatewayRouteTableRequest method. -// req, resp := client.AssociateTransitGatewayRouteTableRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AssociateTransitGatewayRouteTable -func (c *EC2) AssociateTransitGatewayRouteTableRequest(input *AssociateTransitGatewayRouteTableInput) (req *request.Request, output *AssociateTransitGatewayRouteTableOutput) { - op := &request.Operation{ - Name: opAssociateTransitGatewayRouteTable, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &AssociateTransitGatewayRouteTableInput{} - } - - output = &AssociateTransitGatewayRouteTableOutput{} - req = c.newRequest(op, input, output) - return -} - -// AssociateTransitGatewayRouteTable API operation for Amazon Elastic Compute Cloud. -// -// Associates the specified attachment with the specified transit gateway route -// table. You can associate only one route table with an attachment. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation AssociateTransitGatewayRouteTable for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AssociateTransitGatewayRouteTable -func (c *EC2) AssociateTransitGatewayRouteTable(input *AssociateTransitGatewayRouteTableInput) (*AssociateTransitGatewayRouteTableOutput, error) { - req, out := c.AssociateTransitGatewayRouteTableRequest(input) - return out, req.Send() -} - -// AssociateTransitGatewayRouteTableWithContext is the same as AssociateTransitGatewayRouteTable with the addition of -// the ability to pass a context and additional request options. -// -// See AssociateTransitGatewayRouteTable for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) AssociateTransitGatewayRouteTableWithContext(ctx aws.Context, input *AssociateTransitGatewayRouteTableInput, opts ...request.Option) (*AssociateTransitGatewayRouteTableOutput, error) { - req, out := c.AssociateTransitGatewayRouteTableRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAssociateVpcCidrBlock = "AssociateVpcCidrBlock" // AssociateVpcCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the AssociateVpcCidrBlock operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1448,7 +1041,7 @@ func (c *EC2) AssociateVpcCidrBlockRequest(input *AssociateVpcCidrBlockInput) (r // IPv6 CIDR block size is fixed at /56. // // For more information about associating CIDR blocks with your VPC and applicable -// restrictions, see VPC and Subnet Sizing (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html#VPC_Sizing) +// restrictions, see VPC and Subnet Sizing (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html#VPC_Sizing) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -1484,7 +1077,7 @@ const opAttachClassicLinkVpc = "AttachClassicLinkVpc" // AttachClassicLinkVpcRequest generates a "aws/request.Request" representing the // client's request for the AttachClassicLinkVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1569,7 +1162,7 @@ const opAttachInternetGateway = "AttachInternetGateway" // AttachInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the AttachInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1603,7 +1196,8 @@ func (c *EC2) AttachInternetGatewayRequest(input *AttachInternetGatewayInput) (r output = &AttachInternetGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -1611,7 +1205,7 @@ func (c *EC2) AttachInternetGatewayRequest(input *AttachInternetGatewayInput) (r // // Attaches an internet gateway to a VPC, enabling connectivity between the // internet and the VPC. For more information about your VPC and internet gateway, -// see the Amazon Virtual Private Cloud User Guide (https://docs.aws.amazon.com/vpc/latest/userguide/). +// see the Amazon Virtual Private Cloud User Guide (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1646,7 +1240,7 @@ const opAttachNetworkInterface = "AttachNetworkInterface" // AttachNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the AttachNetworkInterface operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1720,7 +1314,7 @@ const opAttachVolume = "AttachVolume" // AttachVolumeRequest generates a "aws/request.Request" representing the // client's request for the AttachVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1762,12 +1356,15 @@ func (c *EC2) AttachVolumeRequest(input *AttachVolumeInput) (req *request.Reques // Attaches an EBS volume to a running or stopped instance and exposes it to // the instance with the specified device name. // -// Encrypted EBS volumes must be attached to instances that support Amazon EBS -// encryption. For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) +// Encrypted EBS volumes may only be attached to instances that support Amazon +// EBS encryption. For more information, see Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. // -// After you attach an EBS volume, you must make it available. For more information, -// see Making an EBS Volume Available For Use (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-using-volumes.html). +// For a list of supported device names, see Attaching an EBS Volume to an Instance +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-attaching-volume.html). +// Any device names that aren't reserved for instance store volumes can be used +// for EBS volumes. For more information, see Amazon EC2 Instance Store (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html) +// in the Amazon Elastic Compute Cloud User Guide. // // If a volume has an AWS Marketplace product code: // @@ -1781,7 +1378,8 @@ func (c *EC2) AttachVolumeRequest(input *AttachVolumeInput) (req *request.Reques // the product. For example, you can't detach a volume from a Windows instance // and attach it to a Linux instance. // -// For more information, see Attaching Amazon EBS Volumes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-attaching-volume.html) +// For more information about EBS volumes, see Attaching Amazon EBS Volumes +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-attaching-volume.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -1817,7 +1415,7 @@ const opAttachVpnGateway = "AttachVpnGateway" // AttachVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the AttachVpnGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -1859,8 +1457,8 @@ func (c *EC2) AttachVpnGatewayRequest(input *AttachVpnGatewayInput) (req *reques // Attaches a virtual private gateway to a VPC. You can attach one virtual private // gateway to one VPC at a time. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information, see AWS Managed VPN Connections (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) +// in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -1890,89 +1488,12 @@ func (c *EC2) AttachVpnGatewayWithContext(ctx aws.Context, input *AttachVpnGatew return out, req.Send() } -const opAuthorizeClientVpnIngress = "AuthorizeClientVpnIngress" - -// AuthorizeClientVpnIngressRequest generates a "aws/request.Request" representing the -// client's request for the AuthorizeClientVpnIngress operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See AuthorizeClientVpnIngress for more information on using the AuthorizeClientVpnIngress -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the AuthorizeClientVpnIngressRequest method. -// req, resp := client.AuthorizeClientVpnIngressRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AuthorizeClientVpnIngress -func (c *EC2) AuthorizeClientVpnIngressRequest(input *AuthorizeClientVpnIngressInput) (req *request.Request, output *AuthorizeClientVpnIngressOutput) { - op := &request.Operation{ - Name: opAuthorizeClientVpnIngress, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &AuthorizeClientVpnIngressInput{} - } - - output = &AuthorizeClientVpnIngressOutput{} - req = c.newRequest(op, input, output) - return -} - -// AuthorizeClientVpnIngress API operation for Amazon Elastic Compute Cloud. -// -// Adds an ingress authorization rule to a Client VPN endpoint. Ingress authorization -// rules act as firewall rules that grant access to networks. You must configure -// ingress authorization rules to enable clients to access resources in AWS -// or on-premises networks. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation AuthorizeClientVpnIngress for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/AuthorizeClientVpnIngress -func (c *EC2) AuthorizeClientVpnIngress(input *AuthorizeClientVpnIngressInput) (*AuthorizeClientVpnIngressOutput, error) { - req, out := c.AuthorizeClientVpnIngressRequest(input) - return out, req.Send() -} - -// AuthorizeClientVpnIngressWithContext is the same as AuthorizeClientVpnIngress with the addition of -// the ability to pass a context and additional request options. -// -// See AuthorizeClientVpnIngress for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) AuthorizeClientVpnIngressWithContext(ctx aws.Context, input *AuthorizeClientVpnIngressInput, opts ...request.Option) (*AuthorizeClientVpnIngressOutput, error) { - req, out := c.AuthorizeClientVpnIngressRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opAuthorizeSecurityGroupEgress = "AuthorizeSecurityGroupEgress" // AuthorizeSecurityGroupEgressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeSecurityGroupEgress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2006,30 +1527,32 @@ func (c *EC2) AuthorizeSecurityGroupEgressRequest(input *AuthorizeSecurityGroupE output = &AuthorizeSecurityGroupEgressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // AuthorizeSecurityGroupEgress API operation for Amazon Elastic Compute Cloud. // -// [VPC only] Adds the specified egress rules to a security group for use with -// a VPC. +// [EC2-VPC only] Adds one or more egress rules to a security group for use +// with a VPC. Specifically, this action permits instances to send traffic to +// one or more destination IPv4 or IPv6 CIDR address ranges, or to one or more +// destination security groups for the same VPC. This action doesn't apply to +// security groups for use in EC2-Classic. For more information, see Security +// Groups for Your VPC (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html) +// in the Amazon Virtual Private Cloud User Guide. For more information about +// security group limits, see Amazon VPC Limits (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Appendix_Limits.html). // -// An outbound rule permits instances to send traffic to the specified IPv4 -// or IPv6 CIDR address ranges, or to the instances associated with the specified -// destination security groups. -// -// You specify a protocol for each rule (for example, TCP). For the TCP and -// UDP protocols, you must also specify the destination port or port range. -// For the ICMP protocol, you must also specify the ICMP type and code. You -// can use -1 for the type or code to mean all types or all codes. +// Each rule consists of the protocol (for example, TCP), plus either a CIDR +// range or a source group. For the TCP and UDP protocols, you must also specify +// the destination port or port range. For the ICMP protocol, you must also +// specify the ICMP type and code. You can use -1 for the type or code to mean +// all types or all codes. You can optionally specify a description for the +// rule. // // Rule changes are propagated to affected instances as quickly as possible. // However, a small delay might occur. // -// For more information about VPC security group limits, see Amazon VPC Limits -// (https://docs.aws.amazon.com/vpc/latest/userguide/amazon-vpc-limits.html). -// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -2063,7 +1586,7 @@ const opAuthorizeSecurityGroupIngress = "AuthorizeSecurityGroupIngress" // AuthorizeSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the AuthorizeSecurityGroupIngress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2097,28 +1620,32 @@ func (c *EC2) AuthorizeSecurityGroupIngressRequest(input *AuthorizeSecurityGroup output = &AuthorizeSecurityGroupIngressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // AuthorizeSecurityGroupIngress API operation for Amazon Elastic Compute Cloud. // -// Adds the specified ingress rules to a security group. -// -// An inbound rule permits instances to receive traffic from the specified IPv4 -// or IPv6 CIDR address ranges, or from the instances associated with the specified -// destination security groups. -// -// You specify a protocol for each rule (for example, TCP). For TCP and UDP, -// you must also specify the destination port or port range. For ICMP/ICMPv6, -// you must also specify the ICMP/ICMPv6 type and code. You can use -1 to mean -// all types or all codes. +// Adds one or more ingress rules to a security group. // // Rule changes are propagated to instances within the security group as quickly // as possible. However, a small delay might occur. // -// For more information about VPC security group limits, see Amazon VPC Limits -// (https://docs.aws.amazon.com/vpc/latest/userguide/amazon-vpc-limits.html). +// [EC2-Classic] This action gives one or more IPv4 CIDR address ranges permission +// to access a security group in your account, or gives one or more security +// groups (called the source groups) permission to access a security group for +// your account. A source group can be for your own AWS account, or another. +// You can have up to 100 rules per group. +// +// [EC2-VPC] This action gives one or more IPv4 or IPv6 CIDR address ranges +// permission to access a security group in your VPC, or gives one or more other +// security groups (called the source groups) permission to access a security +// group for your VPC. The security groups must all be for the same VPC or a +// peer VPC in a VPC peering connection. For more information about VPC security +// group limits, see Amazon VPC Limits (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Appendix_Limits.html). +// +// You can optionally specify a description for the security group rule. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2153,7 +1680,7 @@ const opBundleInstance = "BundleInstance" // BundleInstanceRequest generates a "aws/request.Request" representing the // client's request for the BundleInstance operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2233,7 +1760,7 @@ const opCancelBundleTask = "CancelBundleTask" // CancelBundleTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelBundleTask operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2302,93 +1829,12 @@ func (c *EC2) CancelBundleTaskWithContext(ctx aws.Context, input *CancelBundleTa return out, req.Send() } -const opCancelCapacityReservation = "CancelCapacityReservation" - -// CancelCapacityReservationRequest generates a "aws/request.Request" representing the -// client's request for the CancelCapacityReservation operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CancelCapacityReservation for more information on using the CancelCapacityReservation -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CancelCapacityReservationRequest method. -// req, resp := client.CancelCapacityReservationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CancelCapacityReservation -func (c *EC2) CancelCapacityReservationRequest(input *CancelCapacityReservationInput) (req *request.Request, output *CancelCapacityReservationOutput) { - op := &request.Operation{ - Name: opCancelCapacityReservation, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CancelCapacityReservationInput{} - } - - output = &CancelCapacityReservationOutput{} - req = c.newRequest(op, input, output) - return -} - -// CancelCapacityReservation API operation for Amazon Elastic Compute Cloud. -// -// Cancels the specified Capacity Reservation, releases the reserved capacity, -// and changes the Capacity Reservation's state to cancelled. -// -// Instances running in the reserved capacity continue running until you stop -// them. Stopped instances that target the Capacity Reservation can no longer -// 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. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CancelCapacityReservation for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CancelCapacityReservation -func (c *EC2) CancelCapacityReservation(input *CancelCapacityReservationInput) (*CancelCapacityReservationOutput, error) { - req, out := c.CancelCapacityReservationRequest(input) - return out, req.Send() -} - -// CancelCapacityReservationWithContext is the same as CancelCapacityReservation with the addition of -// the ability to pass a context and additional request options. -// -// See CancelCapacityReservation for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CancelCapacityReservationWithContext(ctx aws.Context, input *CancelCapacityReservationInput, opts ...request.Option) (*CancelCapacityReservationOutput, error) { - req, out := c.CancelCapacityReservationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opCancelConversionTask = "CancelConversionTask" // CancelConversionTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelConversionTask operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2422,7 +1868,8 @@ func (c *EC2) CancelConversionTaskRequest(input *CancelConversionTaskInput) (req output = &CancelConversionTaskOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -2435,7 +1882,7 @@ func (c *EC2) CancelConversionTaskRequest(input *CancelConversionTaskInput) (req // and returns an exception. // // For more information, see Importing a Virtual Machine Using the Amazon EC2 -// CLI (https://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ec2-cli-vmimport-export.html). +// CLI (http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ec2-cli-vmimport-export.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -2470,7 +1917,7 @@ const opCancelExportTask = "CancelExportTask" // CancelExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelExportTask operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2504,7 +1951,8 @@ func (c *EC2) CancelExportTaskRequest(input *CancelExportTaskInput) (req *reques output = &CancelExportTaskOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -2548,7 +1996,7 @@ const opCancelImportTask = "CancelImportTask" // CancelImportTaskRequest generates a "aws/request.Request" representing the // client's request for the CancelImportTask operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2622,7 +2070,7 @@ const opCancelReservedInstancesListing = "CancelReservedInstancesListing" // CancelReservedInstancesListingRequest generates a "aws/request.Request" representing the // client's request for the CancelReservedInstancesListing operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2664,7 +2112,7 @@ func (c *EC2) CancelReservedInstancesListingRequest(input *CancelReservedInstanc // Cancels the specified Reserved Instance listing in the Reserved Instance // Marketplace. // -// For more information, see Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) +// For more information, see Reserved Instance Marketplace (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -2700,7 +2148,7 @@ const opCancelSpotFleetRequests = "CancelSpotFleetRequests" // CancelSpotFleetRequestsRequest generates a "aws/request.Request" representing the // client's request for the CancelSpotFleetRequests operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2781,7 +2229,7 @@ const opCancelSpotInstanceRequests = "CancelSpotInstanceRequests" // CancelSpotInstanceRequestsRequest generates a "aws/request.Request" representing the // client's request for the CancelSpotInstanceRequests operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2858,7 +2306,7 @@ const opConfirmProductInstance = "ConfirmProductInstance" // ConfirmProductInstanceRequest generates a "aws/request.Request" representing the // client's request for the ConfirmProductInstance operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2934,7 +2382,7 @@ const opCopyFpgaImage = "CopyFpgaImage" // CopyFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the CopyFpgaImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -2973,7 +2421,7 @@ func (c *EC2) CopyFpgaImageRequest(input *CopyFpgaImageInput) (req *request.Requ // CopyFpgaImage API operation for Amazon Elastic Compute Cloud. // -// Copies the specified Amazon FPGA Image (AFI) to the current Region. +// Copies the specified Amazon FPGA Image (AFI) to the current region. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -3008,7 +2456,7 @@ const opCopyImage = "CopyImage" // CopyImageRequest generates a "aws/request.Request" representing the // client's request for the CopyImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3047,17 +2495,12 @@ func (c *EC2) CopyImageRequest(input *CopyImageInput) (req *request.Request, out // CopyImage API operation for Amazon Elastic Compute Cloud. // -// Initiates the copy of an AMI from the specified source Region to the current -// Region. You specify the destination Region by using its endpoint when making +// Initiates the copy of an AMI from the specified source region to the current +// region. You specify the destination region by using its endpoint when making // the request. // -// Copies of encrypted backing snapshots for the AMI are encrypted. Copies of -// unencrypted backing snapshots remain unencrypted, unless you set Encrypted -// during the copy operation. You cannot create an unencrypted copy of an encrypted -// backing snapshot. -// // For more information about the prerequisites and limits when copying an AMI, -// see Copying an AMI (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/CopyingAMIs.html) +// see Copying an AMI (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/CopyingAMIs.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3093,7 +2536,7 @@ const opCopySnapshot = "CopySnapshot" // CopySnapshotRequest generates a "aws/request.Request" representing the // client's request for the CopySnapshot operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3133,15 +2576,16 @@ func (c *EC2) CopySnapshotRequest(input *CopySnapshotInput) (req *request.Reques // CopySnapshot API operation for Amazon Elastic Compute Cloud. // // Copies a point-in-time snapshot of an EBS volume and stores it in Amazon -// S3. You can copy the snapshot within the same Region or from one Region to +// S3. You can copy the snapshot within the same region or from one region to // another. You can use the snapshot to create EBS volumes or Amazon Machine -// Images (AMIs). +// Images (AMIs). The snapshot is copied to the regional endpoint that you send +// the HTTP request to. // // Copies of encrypted EBS snapshots remain encrypted. Copies of unencrypted -// snapshots remain unencrypted, unless you enable encryption for the snapshot -// copy operation. By default, encrypted snapshot copies use the default AWS -// Key Management Service (AWS KMS) customer master key (CMK); however, you -// can specify a different CMK. +// snapshots remain unencrypted, unless the Encrypted flag is specified during +// the snapshot copy operation. By default, encrypted snapshot copies use the +// default AWS Key Management Service (AWS KMS) customer master key (CMK); however, +// you can specify a non-default CMK with the KmsKeyId parameter. // // To copy an encrypted snapshot that has been shared from another account, // you must have permissions for the CMK used to encrypt the snapshot. @@ -3149,7 +2593,7 @@ func (c *EC2) CopySnapshotRequest(input *CopySnapshotInput) (req *request.Reques // Snapshots created by copying another snapshot have an arbitrary volume ID // that should not be used for any purpose. // -// For more information, see Copying an Amazon EBS Snapshot (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-copy-snapshot.html) +// For more information, see Copying an Amazon EBS Snapshot (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-copy-snapshot.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3180,262 +2624,12 @@ func (c *EC2) CopySnapshotWithContext(ctx aws.Context, input *CopySnapshotInput, return out, req.Send() } -const opCreateCapacityReservation = "CreateCapacityReservation" - -// CreateCapacityReservationRequest generates a "aws/request.Request" representing the -// client's request for the CreateCapacityReservation operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateCapacityReservation for more information on using the CreateCapacityReservation -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateCapacityReservationRequest method. -// req, resp := client.CreateCapacityReservationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateCapacityReservation -func (c *EC2) CreateCapacityReservationRequest(input *CreateCapacityReservationInput) (req *request.Request, output *CreateCapacityReservationOutput) { - op := &request.Operation{ - Name: opCreateCapacityReservation, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateCapacityReservationInput{} - } - - output = &CreateCapacityReservationOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateCapacityReservation API operation for Amazon Elastic Compute Cloud. -// -// Creates a new Capacity Reservation with the specified attributes. -// -// Capacity Reservations enable you to reserve capacity for your Amazon EC2 -// instances in a specific Availability Zone for any duration. This gives you -// the flexibility to selectively add capacity reservations and still get the -// Regional RI discounts for that usage. By creating Capacity Reservations, -// you ensure that you always have access to Amazon EC2 capacity when you need -// it, for as long as you need it. For more information, see Capacity Reservations -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-capacity-reservations.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Your request to create a Capacity Reservation could fail if Amazon EC2 does -// not have sufficient capacity to fulfill the request. If your request fails -// due to Amazon EC2 capacity constraints, either try again at a later time, -// try in a different Availability Zone, or request a smaller capacity reservation. -// If your application is flexible across instance types and sizes, try to create -// a Capacity Reservation with different instance attributes. -// -// Your request could also fail if the requested quantity exceeds your On-Demand -// Instance limit for the selected instance type. If your request fails due -// to limit constraints, increase your On-Demand Instance limit for the required -// instance type and try again. For more information about increasing your instance -// limits, see Amazon EC2 Service Limits (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-resource-limits.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateCapacityReservation for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateCapacityReservation -func (c *EC2) CreateCapacityReservation(input *CreateCapacityReservationInput) (*CreateCapacityReservationOutput, error) { - req, out := c.CreateCapacityReservationRequest(input) - return out, req.Send() -} - -// CreateCapacityReservationWithContext is the same as CreateCapacityReservation with the addition of -// the ability to pass a context and additional request options. -// -// See CreateCapacityReservation for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateCapacityReservationWithContext(ctx aws.Context, input *CreateCapacityReservationInput, opts ...request.Option) (*CreateCapacityReservationOutput, error) { - req, out := c.CreateCapacityReservationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateClientVpnEndpoint = "CreateClientVpnEndpoint" - -// CreateClientVpnEndpointRequest generates a "aws/request.Request" representing the -// client's request for the CreateClientVpnEndpoint operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateClientVpnEndpoint for more information on using the CreateClientVpnEndpoint -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateClientVpnEndpointRequest method. -// req, resp := client.CreateClientVpnEndpointRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateClientVpnEndpoint -func (c *EC2) CreateClientVpnEndpointRequest(input *CreateClientVpnEndpointInput) (req *request.Request, output *CreateClientVpnEndpointOutput) { - op := &request.Operation{ - Name: opCreateClientVpnEndpoint, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateClientVpnEndpointInput{} - } - - output = &CreateClientVpnEndpointOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateClientVpnEndpoint API operation for Amazon Elastic Compute Cloud. -// -// Creates a Client VPN endpoint. A Client VPN endpoint is the resource you -// create and configure to enable and manage client VPN sessions. It is the -// destination endpoint at which all client VPN sessions are terminated. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateClientVpnEndpoint for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateClientVpnEndpoint -func (c *EC2) CreateClientVpnEndpoint(input *CreateClientVpnEndpointInput) (*CreateClientVpnEndpointOutput, error) { - req, out := c.CreateClientVpnEndpointRequest(input) - return out, req.Send() -} - -// CreateClientVpnEndpointWithContext is the same as CreateClientVpnEndpoint with the addition of -// the ability to pass a context and additional request options. -// -// See CreateClientVpnEndpoint for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateClientVpnEndpointWithContext(ctx aws.Context, input *CreateClientVpnEndpointInput, opts ...request.Option) (*CreateClientVpnEndpointOutput, error) { - req, out := c.CreateClientVpnEndpointRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateClientVpnRoute = "CreateClientVpnRoute" - -// CreateClientVpnRouteRequest generates a "aws/request.Request" representing the -// client's request for the CreateClientVpnRoute operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateClientVpnRoute for more information on using the CreateClientVpnRoute -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateClientVpnRouteRequest method. -// req, resp := client.CreateClientVpnRouteRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateClientVpnRoute -func (c *EC2) CreateClientVpnRouteRequest(input *CreateClientVpnRouteInput) (req *request.Request, output *CreateClientVpnRouteOutput) { - op := &request.Operation{ - Name: opCreateClientVpnRoute, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateClientVpnRouteInput{} - } - - output = &CreateClientVpnRouteOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateClientVpnRoute API operation for Amazon Elastic Compute Cloud. -// -// Adds a route to a network to a Client VPN endpoint. Each Client VPN endpoint -// has a route table that describes the available destination network routes. -// Each route in the route table specifies the path for traffic to specific -// resources or networks. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateClientVpnRoute for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateClientVpnRoute -func (c *EC2) CreateClientVpnRoute(input *CreateClientVpnRouteInput) (*CreateClientVpnRouteOutput, error) { - req, out := c.CreateClientVpnRouteRequest(input) - return out, req.Send() -} - -// CreateClientVpnRouteWithContext is the same as CreateClientVpnRoute with the addition of -// the ability to pass a context and additional request options. -// -// See CreateClientVpnRoute for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateClientVpnRouteWithContext(ctx aws.Context, input *CreateClientVpnRouteInput, opts ...request.Option) (*CreateClientVpnRouteOutput, error) { - req, out := c.CreateClientVpnRouteRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opCreateCustomerGateway = "CreateCustomerGateway" // CreateCustomerGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateCustomerGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3487,11 +2681,12 @@ func (c *EC2) CreateCustomerGatewayRequest(input *CreateCustomerGatewayInput) (r // a private ASN (in the 64512 - 65534 range). // // Amazon EC2 supports all 2-byte ASN numbers in the range of 1 - 65534, with -// the exception of 7224, which is reserved in the us-east-1 Region, and 9059, -// which is reserved in the eu-west-1 Region. +// the exception of 7224, which is reserved in the us-east-1 region, and 9059, +// which is reserved in the eu-west-1 region. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about VPN customer gateways, see AWS Managed VPN Connections +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) in the +// Amazon Virtual Private Cloud User Guide. // // You cannot create more than one customer gateway with the same VPN type, // IP address, and BGP ASN parameter values. If you run an identical request @@ -3532,7 +2727,7 @@ const opCreateDefaultSubnet = "CreateDefaultSubnet" // CreateDefaultSubnetRequest generates a "aws/request.Request" representing the // client's request for the CreateDefaultSubnet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3574,7 +2769,7 @@ func (c *EC2) CreateDefaultSubnetRequest(input *CreateDefaultSubnetInput) (req * // Creates a default subnet with a size /20 IPv4 CIDR block in the specified // Availability Zone in your default VPC. You can have only one default subnet // per Availability Zone. For more information, see Creating a Default Subnet -// (https://docs.aws.amazon.com/vpc/latest/userguide/default-vpc.html#create-default-subnet) +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/default-vpc.html#create-default-subnet) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3610,7 +2805,7 @@ const opCreateDefaultVpc = "CreateDefaultVpc" // CreateDefaultVpcRequest generates a "aws/request.Request" representing the // client's request for the CreateDefaultVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3651,12 +2846,12 @@ func (c *EC2) CreateDefaultVpcRequest(input *CreateDefaultVpcInput) (req *reques // // Creates a default VPC with a size /16 IPv4 CIDR block and a default subnet // in each Availability Zone. For more information about the components of a -// default VPC, see Default VPC and Default Subnets (https://docs.aws.amazon.com/vpc/latest/userguide/default-vpc.html) +// default VPC, see Default VPC and Default Subnets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/default-vpc.html) // in the Amazon Virtual Private Cloud User Guide. You cannot specify the components // of the default VPC yourself. // -// If you deleted your previous default VPC, you can create a default VPC. You -// cannot have more than one default VPC per Region. +// iIf you deleted your previous default VPC, you can create a default VPC. +// You cannot have more than one default VPC per Region. // // If your account supports EC2-Classic, you cannot use this action to create // a default VPC in a Region that supports EC2-Classic. If you want a default @@ -3696,7 +2891,7 @@ const opCreateDhcpOptions = "CreateDhcpOptions" // CreateDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the CreateDhcpOptions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3749,7 +2944,7 @@ func (c *EC2) CreateDhcpOptionsRequest(input *CreateDhcpOptionsInput) (req *requ // domain-name-servers to a custom DNS server. // // * domain-name - If you're using AmazonProvidedDNS in us-east-1, specify -// ec2.internal. If you're using AmazonProvidedDNS in another Region, specify +// ec2.internal. If you're using AmazonProvidedDNS in another region, specify // region.compute.internal (for example, ap-northeast-1.compute.internal). // Otherwise, specify a domain name (for example, MyCompany.com). This value // is used to complete unqualified DNS hostnames. Important: Some Linux operating @@ -3772,7 +2967,7 @@ func (c *EC2) CreateDhcpOptionsRequest(input *CreateDhcpOptionsInput) (req *requ // only a DNS server that we provide (AmazonProvidedDNS). If you create a set // of options, and if your VPC has an internet gateway, make sure to set the // domain-name-servers option either to AmazonProvidedDNS or to a domain name -// server of your choice. For more information, see DHCP Options Sets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_DHCP_Options.html) +// server of your choice. For more information, see DHCP Options Sets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_DHCP_Options.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3808,7 +3003,7 @@ const opCreateEgressOnlyInternetGateway = "CreateEgressOnlyInternetGateway" // CreateEgressOnlyInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateEgressOnlyInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3885,7 +3080,7 @@ const opCreateFleet = "CreateFleet" // CreateFleetRequest generates a "aws/request.Request" representing the // client's request for the CreateFleet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -3929,7 +3124,7 @@ func (c *EC2) CreateFleetRequest(input *CreateFleetInput) (req *request.Request, // You can create a single EC2 Fleet that includes multiple launch specifications // that vary by instance type, AMI, Availability Zone, or subnet. // -// For more information, see Launching an EC2 Fleet (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet.html) +// For more information, see Launching an EC2 Fleet (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -3965,7 +3160,7 @@ const opCreateFlowLogs = "CreateFlowLogs" // CreateFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the CreateFlowLogs operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4009,7 +3204,7 @@ func (c *EC2) CreateFlowLogsRequest(input *CreateFlowLogsInput) (req *request.Re // // Flow log data for a monitored network interface is recorded as flow log records, // which are log events consisting of fields that describe the traffic flow. -// For more information, see Flow Log Records (https://docs.aws.amazon.com/vpc/latest/userguide/flow-logs.html#flow-log-records) +// For more information, see Flow Log Records (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/flow-logs.html#flow-log-records) // in the Amazon Virtual Private Cloud User Guide. // // When publishing to CloudWatch Logs, flow log records are published to a log @@ -4018,7 +3213,7 @@ func (c *EC2) CreateFlowLogsRequest(input *CreateFlowLogsInput) (req *request.Re // interfaces are published to a single log file object that is stored in the // specified bucket. // -// For more information, see VPC Flow Logs (https://docs.aws.amazon.com/vpc/latest/userguide/flow-logs.html) +// For more information, see VPC Flow Logs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/flow-logs.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4054,7 +3249,7 @@ const opCreateFpgaImage = "CreateFpgaImage" // CreateFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the CreateFpgaImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4099,8 +3294,8 @@ func (c *EC2) CreateFpgaImageRequest(input *CreateFpgaImageInput) (req *request. // use, check the output logs. // // An AFI contains the FPGA bitstream that is ready to download to an FPGA. -// You can securely deploy an AFI on multiple FPGA-accelerated instances. For -// more information, see the AWS FPGA Hardware Development Kit (https://github.com/aws/aws-fpga/). +// You can securely deploy an AFI on one or more FPGA-accelerated instances. +// For more information, see the AWS FPGA Hardware Development Kit (https://github.com/aws/aws-fpga/). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -4135,7 +3330,7 @@ const opCreateImage = "CreateImage" // CreateImageRequest generates a "aws/request.Request" representing the // client's request for the CreateImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4182,7 +3377,7 @@ func (c *EC2) CreateImageRequest(input *CreateImageInput) (req *request.Request, // mapping information for those volumes. When you launch an instance from this // new AMI, the instance automatically launches with those additional volumes. // -// For more information, see Creating Amazon EBS-Backed Linux AMIs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/creating-an-ami-ebs.html) +// For more information, see Creating Amazon EBS-Backed Linux AMIs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/creating-an-ami-ebs.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4218,7 +3413,7 @@ const opCreateInstanceExportTask = "CreateInstanceExportTask" // CreateInstanceExportTaskRequest generates a "aws/request.Request" representing the // client's request for the CreateInstanceExportTask operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4261,7 +3456,7 @@ func (c *EC2) CreateInstanceExportTaskRequest(input *CreateInstanceExportTaskInp // // For information about the supported operating systems, image formats, and // known limitations for the types of instances you can export, see Exporting -// an Instance as a VM Using VM Import/Export (https://docs.aws.amazon.com/vm-import/latest/userguide/vmexport.html) +// an Instance as a VM Using VM Import/Export (http://docs.aws.amazon.com/vm-import/latest/userguide/vmexport.html) // in the VM Import/Export User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4297,7 +3492,7 @@ const opCreateInternetGateway = "CreateInternetGateway" // CreateInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4340,7 +3535,7 @@ func (c *EC2) CreateInternetGatewayRequest(input *CreateInternetGatewayInput) (r // gateway, you attach it to a VPC using AttachInternetGateway. // // For more information about your VPC and internet gateway, see the Amazon -// Virtual Private Cloud User Guide (https://docs.aws.amazon.com/vpc/latest/userguide/). +// Virtual Private Cloud User Guide (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -4375,7 +3570,7 @@ const opCreateKeyPair = "CreateKeyPair" // CreateKeyPairRequest generates a "aws/request.Request" representing the // client's request for the CreateKeyPair operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4419,13 +3614,13 @@ func (c *EC2) CreateKeyPairRequest(input *CreateKeyPairInput) (req *request.Requ // private key is returned as an unencrypted PEM encoded PKCS#1 private key. // If a key with the specified name already exists, Amazon EC2 returns an error. // -// You can have up to five thousand key pairs per Region. +// You can have up to five thousand key pairs per region. // -// The key pair returned to you is available only in the Region in which you +// The key pair returned to you is available only in the region in which you // create it. If you prefer, you can create your own key pair using a third-party -// tool and upload it to any Region using ImportKeyPair. +// tool and upload it to any region using ImportKeyPair. // -// For more information, see Key Pairs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) +// For more information, see Key Pairs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4461,7 +3656,7 @@ const opCreateLaunchTemplate = "CreateLaunchTemplate" // CreateLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the CreateLaunchTemplate operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4537,7 +3732,7 @@ const opCreateLaunchTemplateVersion = "CreateLaunchTemplateVersion" // CreateLaunchTemplateVersionRequest generates a "aws/request.Request" representing the // client's request for the CreateLaunchTemplateVersion operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4615,7 +3810,7 @@ const opCreateNatGateway = "CreateNatGateway" // CreateNatGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateNatGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4659,7 +3854,7 @@ func (c *EC2) CreateNatGatewayRequest(input *CreateNatGatewayInput) (req *reques // the IP address range of the subnet. Internet-bound traffic from a private // subnet can be routed to the NAT gateway, therefore enabling instances in // the private subnet to connect to the internet. For more information, see -// NAT Gateways (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html) +// NAT Gateways (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4695,7 +3890,7 @@ const opCreateNetworkAcl = "CreateNetworkAcl" // CreateNetworkAclRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkAcl operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4737,7 +3932,7 @@ func (c *EC2) CreateNetworkAclRequest(input *CreateNetworkAclInput) (req *reques // Creates a network ACL in a VPC. Network ACLs provide an optional layer of // security (in addition to security groups) for the instances in your VPC. // -// For more information, see Network ACLs (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_ACLs.html) +// For more information, see Network ACLs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4773,7 +3968,7 @@ const opCreateNetworkAclEntry = "CreateNetworkAclEntry" // CreateNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkAclEntry operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4807,7 +4002,8 @@ func (c *EC2) CreateNetworkAclEntryRequest(input *CreateNetworkAclEntryInput) (r output = &CreateNetworkAclEntryOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -4828,7 +4024,7 @@ func (c *EC2) CreateNetworkAclEntryRequest(input *CreateNetworkAclEntryInput) (r // After you add an entry, you can't modify it; you must either replace it, // or create an entry and delete the old one. // -// For more information about network ACLs, see Network ACLs (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_ACLs.html) +// For more information about network ACLs, see Network ACLs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4864,7 +4060,7 @@ const opCreateNetworkInterface = "CreateNetworkInterface" // CreateNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkInterface operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -4906,7 +4102,7 @@ func (c *EC2) CreateNetworkInterfaceRequest(input *CreateNetworkInterfaceInput) // Creates a network interface in the specified subnet. // // For more information about network interfaces, see Elastic Network Interfaces -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html) in the +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html) in the // Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -4942,7 +4138,7 @@ const opCreateNetworkInterfacePermission = "CreateNetworkInterfacePermission" // CreateNetworkInterfacePermissionRequest generates a "aws/request.Request" representing the // client's request for the CreateNetworkInterfacePermission operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5020,7 +4216,7 @@ const opCreatePlacementGroup = "CreatePlacementGroup" // CreatePlacementGroupRequest generates a "aws/request.Request" representing the // client's request for the CreatePlacementGroup operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5054,7 +4250,8 @@ func (c *EC2) CreatePlacementGroupRequest(input *CreatePlacementGroupInput) (req output = &CreatePlacementGroupOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -5065,12 +4262,9 @@ func (c *EC2) CreatePlacementGroupRequest(input *CreatePlacementGroupInput) (req // // A cluster placement group is a logical grouping of instances within a single // Availability Zone that benefit from low network latency, high network throughput. -// A spread placement group places instances on distinct hardware. A partition -// placement group places groups of instances in different partitions, where -// instances in one partition do not share the same hardware with instances -// in another partition. +// A spread placement group places instances on distinct hardware. // -// For more information, see Placement Groups (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) +// For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5106,7 +4300,7 @@ const opCreateReservedInstancesListing = "CreateReservedInstancesListing" // CreateReservedInstancesListingRequest generates a "aws/request.Request" representing the // client's request for the CreateReservedInstancesListing operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5150,8 +4344,9 @@ func (c *EC2) CreateReservedInstancesListingRequest(input *CreateReservedInstanc // listing at a time. To get a list of your Standard Reserved Instances, you // can use the DescribeReservedInstances operation. // -// Only Standard Reserved Instances can be sold in the Reserved Instance Marketplace. -// Convertible Reserved Instances cannot be sold. +// Only Standard Reserved Instances with a capacity reservation can be sold +// in the Reserved Instance Marketplace. Convertible Reserved Instances and +// Standard Reserved Instances with a regional benefit cannot be sold. // // The Reserved Instance Marketplace matches sellers who want to resell Standard // Reserved Instance capacity that they no longer need with buyers who want @@ -5166,7 +4361,7 @@ func (c *EC2) CreateReservedInstancesListingRequest(input *CreateReservedInstanc // for purchase. To view the details of your Standard Reserved Instance listing, // you can use the DescribeReservedInstancesListings operation. // -// For more information, see Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) +// For more information, see Reserved Instance Marketplace (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5202,7 +4397,7 @@ const opCreateRoute = "CreateRoute" // CreateRouteRequest generates a "aws/request.Request" representing the // client's request for the CreateRoute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5259,7 +4454,7 @@ func (c *EC2) CreateRouteRequest(input *CreateRouteInput) (req *request.Request, // route in the list covers a smaller number of IP addresses and is therefore // more specific, so we use that route to determine where to target the traffic. // -// For more information about route tables, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// For more information about route tables, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5295,7 +4490,7 @@ const opCreateRouteTable = "CreateRouteTable" // CreateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the CreateRouteTable operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5337,7 +4532,7 @@ func (c *EC2) CreateRouteTableRequest(input *CreateRouteTableInput) (req *reques // Creates a route table for the specified VPC. After you create a route table, // you can add routes and associate the table with a subnet. // -// For more information, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// For more information, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5373,7 +4568,7 @@ const opCreateSecurityGroup = "CreateSecurityGroup" // CreateSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the CreateSecurityGroup operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5414,13 +4609,17 @@ func (c *EC2) CreateSecurityGroupRequest(input *CreateSecurityGroupInput) (req * // // Creates a security group. // -// A security group acts as a virtual firewall for your instance to control -// inbound and outbound traffic. For more information, see Amazon EC2 Security -// Groups (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html) +// A security group is for use with instances either in the EC2-Classic platform +// or in a specific VPC. For more information, see Amazon EC2 Security Groups +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html) // in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your -// VPC (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html) +// VPC (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html) // in the Amazon Virtual Private Cloud User Guide. // +// EC2-Classic: You can have up to 500 security groups. +// +// EC2-VPC: You can create up to 500 security groups per VPC. +// // When you create a security group, you specify a friendly name of your choice. // You can have a security group for use in EC2-Classic with the same name as // a security group for use in a VPC. However, you can't have two security groups @@ -5436,9 +4635,6 @@ func (c *EC2) CreateSecurityGroupRequest(input *CreateSecurityGroupInput) (req * // You can add or remove rules from your security groups using AuthorizeSecurityGroupIngress, // AuthorizeSecurityGroupEgress, RevokeSecurityGroupIngress, and RevokeSecurityGroupEgress. // -// For more information about VPC security group limits, see Amazon VPC Limits -// (https://docs.aws.amazon.com/vpc/latest/userguide/amazon-vpc-limits.html). -// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -5472,7 +4668,7 @@ const opCreateSnapshot = "CreateSnapshot" // CreateSnapshotRequest generates a "aws/request.Request" representing the // client's request for the CreateSnapshot operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5537,11 +4733,11 @@ func (c *EC2) CreateSnapshotRequest(input *CreateSnapshotInput) (req *request.Re // protected. // // You can tag your snapshots during creation. For more information, see Tagging -// Your Amazon EC2 Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) +// Your Amazon EC2 Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) // in the Amazon Elastic Compute Cloud User Guide. // -// For more information, see Amazon Elastic Block Store (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AmazonEBS.html) -// and Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) +// For more information, see Amazon Elastic Block Store (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AmazonEBS.html) +// and Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5572,89 +4768,12 @@ func (c *EC2) CreateSnapshotWithContext(ctx aws.Context, input *CreateSnapshotIn return out, req.Send() } -const opCreateSnapshots = "CreateSnapshots" - -// CreateSnapshotsRequest generates a "aws/request.Request" representing the -// client's request for the CreateSnapshots operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateSnapshots for more information on using the CreateSnapshots -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateSnapshotsRequest method. -// req, resp := client.CreateSnapshotsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateSnapshots -func (c *EC2) CreateSnapshotsRequest(input *CreateSnapshotsInput) (req *request.Request, output *CreateSnapshotsOutput) { - op := &request.Operation{ - Name: opCreateSnapshots, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateSnapshotsInput{} - } - - output = &CreateSnapshotsOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateSnapshots API operation for Amazon Elastic Compute Cloud. -// -// Creates crash-consistent snapshots of multiple EBS volumes and stores the -// data in S3. Volumes are chosen by specifying an instance. Any attached volumes -// will produce one snapshot each that is crash-consistent across the instance. -// Boot volumes can be excluded by changing the paramaters. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateSnapshots for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateSnapshots -func (c *EC2) CreateSnapshots(input *CreateSnapshotsInput) (*CreateSnapshotsOutput, error) { - req, out := c.CreateSnapshotsRequest(input) - return out, req.Send() -} - -// CreateSnapshotsWithContext is the same as CreateSnapshots with the addition of -// the ability to pass a context and additional request options. -// -// See CreateSnapshots for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateSnapshotsWithContext(ctx aws.Context, input *CreateSnapshotsInput, opts ...request.Option) (*CreateSnapshotsOutput, error) { - req, out := c.CreateSnapshotsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opCreateSpotDatafeedSubscription = "CreateSpotDatafeedSubscription" // CreateSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the CreateSpotDatafeedSubscription operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5695,7 +4814,7 @@ func (c *EC2) CreateSpotDatafeedSubscriptionRequest(input *CreateSpotDatafeedSub // // Creates a data feed for Spot Instances, enabling you to view Spot Instance // usage logs. You can create one data feed per AWS account. For more information, -// see Spot Instance Data Feed (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-data-feeds.html) +// see Spot Instance Data Feed (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-data-feeds.html) // in the Amazon EC2 User Guide for Linux Instances. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5731,7 +4850,7 @@ const opCreateSubnet = "CreateSubnet" // CreateSubnetRequest generates a "aws/request.Request" representing the // client's request for the CreateSubnet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5795,7 +4914,7 @@ func (c *EC2) CreateSubnetRequest(input *CreateSubnetInput) (req *request.Reques // It's therefore possible to have a subnet with no running instances (they're // all stopped), but no remaining IP addresses available. // -// For more information about subnets, see Your VPC and Subnets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html) +// For more information about subnets, see Your VPC and Subnets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5831,7 +4950,7 @@ const opCreateTags = "CreateTags" // CreateTagsRequest generates a "aws/request.Request" representing the // client's request for the CreateTags operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -5865,20 +4984,21 @@ func (c *EC2) CreateTagsRequest(input *CreateTagsInput) (req *request.Request, o output = &CreateTagsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // CreateTags API operation for Amazon Elastic Compute Cloud. // -// Adds or overwrites the specified tags for the specified Amazon EC2 resource +// Adds or overwrites one or more tags for the specified Amazon EC2 resource // or resources. Each resource can have a maximum of 50 tags. Each tag consists // of a key and optional value. Tag keys must be unique per resource. // -// For more information about tags, see Tagging Your Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) +// For more information about tags, see Tagging Your Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) // in the Amazon Elastic Compute Cloud User Guide. For more information about // creating IAM policies that control users' access to resources based on tags, -// see Supported Resource-Level Permissions for Amazon EC2 API Actions (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-supported-iam-actions-resources.html) +// see Supported Resource-Level Permissions for Amazon EC2 API Actions (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-supported-iam-actions-resources.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -5909,661 +5029,12 @@ func (c *EC2) CreateTagsWithContext(ctx aws.Context, input *CreateTagsInput, opt return out, req.Send() } -const opCreateTrafficMirrorFilter = "CreateTrafficMirrorFilter" - -// CreateTrafficMirrorFilterRequest generates a "aws/request.Request" representing the -// client's request for the CreateTrafficMirrorFilter operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTrafficMirrorFilter for more information on using the CreateTrafficMirrorFilter -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTrafficMirrorFilterRequest method. -// req, resp := client.CreateTrafficMirrorFilterRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorFilter -func (c *EC2) CreateTrafficMirrorFilterRequest(input *CreateTrafficMirrorFilterInput) (req *request.Request, output *CreateTrafficMirrorFilterOutput) { - op := &request.Operation{ - Name: opCreateTrafficMirrorFilter, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTrafficMirrorFilterInput{} - } - - output = &CreateTrafficMirrorFilterOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTrafficMirrorFilter API operation for Amazon Elastic Compute Cloud. -// -// Creates a Traffic Mirror filter. -// -// A Traffic Mirror filter is a set of rules that defines the traffic to mirror. -// -// By default, no traffic is mirrored. To mirror traffic, use CreateTrafficMirrorFilterRule -// to add Traffic Mirror rules to the filter. The rules you add define what -// traffic gets mirrored. You can also use ModifyTrafficMirrorFilterNetworkServices -// to mirror supported network services. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTrafficMirrorFilter for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorFilter -func (c *EC2) CreateTrafficMirrorFilter(input *CreateTrafficMirrorFilterInput) (*CreateTrafficMirrorFilterOutput, error) { - req, out := c.CreateTrafficMirrorFilterRequest(input) - return out, req.Send() -} - -// CreateTrafficMirrorFilterWithContext is the same as CreateTrafficMirrorFilter with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTrafficMirrorFilter for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTrafficMirrorFilterWithContext(ctx aws.Context, input *CreateTrafficMirrorFilterInput, opts ...request.Option) (*CreateTrafficMirrorFilterOutput, error) { - req, out := c.CreateTrafficMirrorFilterRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTrafficMirrorFilterRule = "CreateTrafficMirrorFilterRule" - -// CreateTrafficMirrorFilterRuleRequest generates a "aws/request.Request" representing the -// client's request for the CreateTrafficMirrorFilterRule operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTrafficMirrorFilterRule for more information on using the CreateTrafficMirrorFilterRule -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTrafficMirrorFilterRuleRequest method. -// req, resp := client.CreateTrafficMirrorFilterRuleRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorFilterRule -func (c *EC2) CreateTrafficMirrorFilterRuleRequest(input *CreateTrafficMirrorFilterRuleInput) (req *request.Request, output *CreateTrafficMirrorFilterRuleOutput) { - op := &request.Operation{ - Name: opCreateTrafficMirrorFilterRule, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTrafficMirrorFilterRuleInput{} - } - - output = &CreateTrafficMirrorFilterRuleOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTrafficMirrorFilterRule API operation for Amazon Elastic Compute Cloud. -// -// Creates a Traffic Mirror rule. -// -// A Traffic Mirror rule defines the Traffic Mirror source traffic to mirror. -// -// You need the Traffic Mirror filter ID when you create the rule. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTrafficMirrorFilterRule for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorFilterRule -func (c *EC2) CreateTrafficMirrorFilterRule(input *CreateTrafficMirrorFilterRuleInput) (*CreateTrafficMirrorFilterRuleOutput, error) { - req, out := c.CreateTrafficMirrorFilterRuleRequest(input) - return out, req.Send() -} - -// CreateTrafficMirrorFilterRuleWithContext is the same as CreateTrafficMirrorFilterRule with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTrafficMirrorFilterRule for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTrafficMirrorFilterRuleWithContext(ctx aws.Context, input *CreateTrafficMirrorFilterRuleInput, opts ...request.Option) (*CreateTrafficMirrorFilterRuleOutput, error) { - req, out := c.CreateTrafficMirrorFilterRuleRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTrafficMirrorSession = "CreateTrafficMirrorSession" - -// CreateTrafficMirrorSessionRequest generates a "aws/request.Request" representing the -// client's request for the CreateTrafficMirrorSession operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTrafficMirrorSession for more information on using the CreateTrafficMirrorSession -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTrafficMirrorSessionRequest method. -// req, resp := client.CreateTrafficMirrorSessionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorSession -func (c *EC2) CreateTrafficMirrorSessionRequest(input *CreateTrafficMirrorSessionInput) (req *request.Request, output *CreateTrafficMirrorSessionOutput) { - op := &request.Operation{ - Name: opCreateTrafficMirrorSession, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTrafficMirrorSessionInput{} - } - - output = &CreateTrafficMirrorSessionOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTrafficMirrorSession API operation for Amazon Elastic Compute Cloud. -// -// Creates a Traffic Mirror session. -// -// A Traffic Mirror session actively copies packets from a Traffic Mirror source -// to a Traffic Mirror target. Create a filter, and then assign it to the session -// to define a subset of the traffic to mirror, for example all TCP traffic. -// -// The Traffic Mirror source and the Traffic Mirror target (monitoring appliances) -// can be in the same VPC, or in a different VPC connected via VPC peering or -// a transit gateway. -// -// By default, no traffic is mirrored. Use CreateTrafficMirrorFilter to create -// filter rules that specify the traffic to mirror. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTrafficMirrorSession for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorSession -func (c *EC2) CreateTrafficMirrorSession(input *CreateTrafficMirrorSessionInput) (*CreateTrafficMirrorSessionOutput, error) { - req, out := c.CreateTrafficMirrorSessionRequest(input) - return out, req.Send() -} - -// CreateTrafficMirrorSessionWithContext is the same as CreateTrafficMirrorSession with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTrafficMirrorSession for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTrafficMirrorSessionWithContext(ctx aws.Context, input *CreateTrafficMirrorSessionInput, opts ...request.Option) (*CreateTrafficMirrorSessionOutput, error) { - req, out := c.CreateTrafficMirrorSessionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTrafficMirrorTarget = "CreateTrafficMirrorTarget" - -// CreateTrafficMirrorTargetRequest generates a "aws/request.Request" representing the -// client's request for the CreateTrafficMirrorTarget operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTrafficMirrorTarget for more information on using the CreateTrafficMirrorTarget -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTrafficMirrorTargetRequest method. -// req, resp := client.CreateTrafficMirrorTargetRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorTarget -func (c *EC2) CreateTrafficMirrorTargetRequest(input *CreateTrafficMirrorTargetInput) (req *request.Request, output *CreateTrafficMirrorTargetOutput) { - op := &request.Operation{ - Name: opCreateTrafficMirrorTarget, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTrafficMirrorTargetInput{} - } - - output = &CreateTrafficMirrorTargetOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTrafficMirrorTarget API operation for Amazon Elastic Compute Cloud. -// -// Creates a target for your Traffic Mirror session. -// -// A Traffic Mirror target is the destination for mirrored traffic. The Traffic -// Mirror source and the Traffic Mirror target (monitoring appliances) can be -// in the same VPC, or in different VPCs connected via VPC peering or a transit -// gateway. -// -// A Traffic Mirror target can be a network interface, or a Network Load Balancer. -// -// To use the target in a Traffic Mirror session, use CreateTrafficMirrorSession. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTrafficMirrorTarget for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTrafficMirrorTarget -func (c *EC2) CreateTrafficMirrorTarget(input *CreateTrafficMirrorTargetInput) (*CreateTrafficMirrorTargetOutput, error) { - req, out := c.CreateTrafficMirrorTargetRequest(input) - return out, req.Send() -} - -// CreateTrafficMirrorTargetWithContext is the same as CreateTrafficMirrorTarget with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTrafficMirrorTarget for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTrafficMirrorTargetWithContext(ctx aws.Context, input *CreateTrafficMirrorTargetInput, opts ...request.Option) (*CreateTrafficMirrorTargetOutput, error) { - req, out := c.CreateTrafficMirrorTargetRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTransitGateway = "CreateTransitGateway" - -// CreateTransitGatewayRequest generates a "aws/request.Request" representing the -// client's request for the CreateTransitGateway operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTransitGateway for more information on using the CreateTransitGateway -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTransitGatewayRequest method. -// req, resp := client.CreateTransitGatewayRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGateway -func (c *EC2) CreateTransitGatewayRequest(input *CreateTransitGatewayInput) (req *request.Request, output *CreateTransitGatewayOutput) { - op := &request.Operation{ - Name: opCreateTransitGateway, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTransitGatewayInput{} - } - - output = &CreateTransitGatewayOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTransitGateway API operation for Amazon Elastic Compute Cloud. -// -// Creates a transit gateway. -// -// You can use a transit gateway to interconnect your virtual private clouds -// (VPC) and on-premises networks. After the transit gateway enters the available -// state, you can attach your VPCs and VPN connections to the transit gateway. -// -// To attach your VPCs, use CreateTransitGatewayVpcAttachment. -// -// To attach a VPN connection, use CreateCustomerGateway to create a customer -// gateway and specify the ID of the customer gateway and the ID of the transit -// gateway in a call to CreateVpnConnection. -// -// When you create a transit gateway, we create a default transit gateway route -// table and use it as the default association route table and the default propagation -// route table. You can use CreateTransitGatewayRouteTable to create additional -// transit gateway route tables. If you disable automatic route propagation, -// we do not create a default transit gateway route table. You can use EnableTransitGatewayRouteTablePropagation -// to propagate routes from a resource attachment to a transit gateway route -// table. If you disable automatic associations, you can use AssociateTransitGatewayRouteTable -// to associate a resource attachment with a transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTransitGateway for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGateway -func (c *EC2) CreateTransitGateway(input *CreateTransitGatewayInput) (*CreateTransitGatewayOutput, error) { - req, out := c.CreateTransitGatewayRequest(input) - return out, req.Send() -} - -// CreateTransitGatewayWithContext is the same as CreateTransitGateway with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTransitGateway for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTransitGatewayWithContext(ctx aws.Context, input *CreateTransitGatewayInput, opts ...request.Option) (*CreateTransitGatewayOutput, error) { - req, out := c.CreateTransitGatewayRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTransitGatewayRoute = "CreateTransitGatewayRoute" - -// CreateTransitGatewayRouteRequest generates a "aws/request.Request" representing the -// client's request for the CreateTransitGatewayRoute operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTransitGatewayRoute for more information on using the CreateTransitGatewayRoute -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTransitGatewayRouteRequest method. -// req, resp := client.CreateTransitGatewayRouteRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayRoute -func (c *EC2) CreateTransitGatewayRouteRequest(input *CreateTransitGatewayRouteInput) (req *request.Request, output *CreateTransitGatewayRouteOutput) { - op := &request.Operation{ - Name: opCreateTransitGatewayRoute, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTransitGatewayRouteInput{} - } - - output = &CreateTransitGatewayRouteOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTransitGatewayRoute API operation for Amazon Elastic Compute Cloud. -// -// Creates a static route for the specified transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTransitGatewayRoute for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayRoute -func (c *EC2) CreateTransitGatewayRoute(input *CreateTransitGatewayRouteInput) (*CreateTransitGatewayRouteOutput, error) { - req, out := c.CreateTransitGatewayRouteRequest(input) - return out, req.Send() -} - -// CreateTransitGatewayRouteWithContext is the same as CreateTransitGatewayRoute with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTransitGatewayRoute for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTransitGatewayRouteWithContext(ctx aws.Context, input *CreateTransitGatewayRouteInput, opts ...request.Option) (*CreateTransitGatewayRouteOutput, error) { - req, out := c.CreateTransitGatewayRouteRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTransitGatewayRouteTable = "CreateTransitGatewayRouteTable" - -// CreateTransitGatewayRouteTableRequest generates a "aws/request.Request" representing the -// client's request for the CreateTransitGatewayRouteTable operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTransitGatewayRouteTable for more information on using the CreateTransitGatewayRouteTable -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTransitGatewayRouteTableRequest method. -// req, resp := client.CreateTransitGatewayRouteTableRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayRouteTable -func (c *EC2) CreateTransitGatewayRouteTableRequest(input *CreateTransitGatewayRouteTableInput) (req *request.Request, output *CreateTransitGatewayRouteTableOutput) { - op := &request.Operation{ - Name: opCreateTransitGatewayRouteTable, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTransitGatewayRouteTableInput{} - } - - output = &CreateTransitGatewayRouteTableOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTransitGatewayRouteTable API operation for Amazon Elastic Compute Cloud. -// -// Creates a route table for the specified transit gateway. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTransitGatewayRouteTable for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayRouteTable -func (c *EC2) CreateTransitGatewayRouteTable(input *CreateTransitGatewayRouteTableInput) (*CreateTransitGatewayRouteTableOutput, error) { - req, out := c.CreateTransitGatewayRouteTableRequest(input) - return out, req.Send() -} - -// CreateTransitGatewayRouteTableWithContext is the same as CreateTransitGatewayRouteTable with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTransitGatewayRouteTable for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTransitGatewayRouteTableWithContext(ctx aws.Context, input *CreateTransitGatewayRouteTableInput, opts ...request.Option) (*CreateTransitGatewayRouteTableOutput, error) { - req, out := c.CreateTransitGatewayRouteTableRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opCreateTransitGatewayVpcAttachment = "CreateTransitGatewayVpcAttachment" - -// CreateTransitGatewayVpcAttachmentRequest generates a "aws/request.Request" representing the -// client's request for the CreateTransitGatewayVpcAttachment operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See CreateTransitGatewayVpcAttachment for more information on using the CreateTransitGatewayVpcAttachment -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the CreateTransitGatewayVpcAttachmentRequest method. -// req, resp := client.CreateTransitGatewayVpcAttachmentRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayVpcAttachment -func (c *EC2) CreateTransitGatewayVpcAttachmentRequest(input *CreateTransitGatewayVpcAttachmentInput) (req *request.Request, output *CreateTransitGatewayVpcAttachmentOutput) { - op := &request.Operation{ - Name: opCreateTransitGatewayVpcAttachment, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &CreateTransitGatewayVpcAttachmentInput{} - } - - output = &CreateTransitGatewayVpcAttachmentOutput{} - req = c.newRequest(op, input, output) - return -} - -// CreateTransitGatewayVpcAttachment API operation for Amazon Elastic Compute Cloud. -// -// Attaches the specified VPC to the specified transit gateway. -// -// If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC -// that is already attached, the new VPC CIDR range is not propagated to the -// default propagation route table. -// -// To send VPC traffic to an attached transit gateway, add a route to the VPC -// route table using CreateRoute. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation CreateTransitGatewayVpcAttachment for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/CreateTransitGatewayVpcAttachment -func (c *EC2) CreateTransitGatewayVpcAttachment(input *CreateTransitGatewayVpcAttachmentInput) (*CreateTransitGatewayVpcAttachmentOutput, error) { - req, out := c.CreateTransitGatewayVpcAttachmentRequest(input) - return out, req.Send() -} - -// CreateTransitGatewayVpcAttachmentWithContext is the same as CreateTransitGatewayVpcAttachment with the addition of -// the ability to pass a context and additional request options. -// -// See CreateTransitGatewayVpcAttachment for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) CreateTransitGatewayVpcAttachmentWithContext(ctx aws.Context, input *CreateTransitGatewayVpcAttachmentInput, opts ...request.Option) (*CreateTransitGatewayVpcAttachmentOutput, error) { - req, out := c.CreateTransitGatewayVpcAttachmentRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opCreateVolume = "CreateVolume" // CreateVolumeRequest generates a "aws/request.Request" representing the // client's request for the CreateVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -6604,23 +5075,23 @@ func (c *EC2) CreateVolumeRequest(input *CreateVolumeInput) (req *request.Reques // // Creates an EBS volume that can be attached to an instance in the same Availability // Zone. The volume is created in the regional endpoint that you send the HTTP -// request to. For more information see Regions and Endpoints (https://docs.aws.amazon.com/general/latest/gr/rande.html). +// request to. For more information see Regions and Endpoints (http://docs.aws.amazon.com/general/latest/gr/rande.html). // // You can create a new empty volume or restore a volume from an EBS snapshot. // Any AWS Marketplace product codes from the snapshot are propagated to the // volume. // -// You can create encrypted volumes. Encrypted volumes must be attached to instances -// that support Amazon EBS encryption. Volumes that are created from encrypted -// snapshots are also automatically encrypted. For more information, see Amazon -// EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) +// You can create encrypted volumes with the Encrypted parameter. Encrypted +// volumes may only be attached to instances that support Amazon EBS encryption. +// Volumes that are created from encrypted snapshots are also automatically +// encrypted. For more information, see Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. // // You can tag your volumes during creation. For more information, see Tagging -// Your Amazon EC2 Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) +// Your Amazon EC2 Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) // in the Amazon Elastic Compute Cloud User Guide. // -// For more information, see Creating an Amazon EBS Volume (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-creating-volume.html) +// For more information, see Creating an Amazon EBS Volume (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-creating-volume.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -6656,7 +5127,7 @@ const opCreateVpc = "CreateVpc" // CreateVpcRequest generates a "aws/request.Request" representing the // client's request for the CreateVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -6698,7 +5169,7 @@ func (c *EC2) CreateVpcRequest(input *CreateVpcInput) (req *request.Request, out // Creates a VPC with the specified IPv4 CIDR block. The smallest VPC you can // create uses a /28 netmask (16 IPv4 addresses), and the largest uses a /16 // netmask (65,536 IPv4 addresses). For more information about how large to -// make your VPC, see Your VPC and Subnets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html) +// make your VPC, see Your VPC and Subnets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html) // in the Amazon Virtual Private Cloud User Guide. // // You can optionally request an Amazon-provided IPv6 CIDR block for the VPC. @@ -6707,12 +5178,12 @@ func (c *EC2) CreateVpcRequest(input *CreateVpcInput) (req *request.Request, out // // By default, each instance you launch in the VPC has the default DHCP options, // which include only a default DNS server that we provide (AmazonProvidedDNS). -// For more information, see DHCP Options Sets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_DHCP_Options.html) +// For more information, see DHCP Options Sets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_DHCP_Options.html) // in the Amazon Virtual Private Cloud User Guide. // // You can specify the instance tenancy value for the VPC when you create it. // You can't change this value for the VPC after you create it. For more information, -// see Dedicated Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-instance.html) +// see Dedicated Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-instance.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -6748,7 +5219,7 @@ const opCreateVpcEndpoint = "CreateVpcEndpoint" // CreateVpcEndpointRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpoint operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -6790,7 +5261,7 @@ func (c *EC2) CreateVpcEndpointRequest(input *CreateVpcEndpointInput) (req *requ // Creates a VPC endpoint for a specified service. An endpoint enables you to // create a private connection between your VPC and the service. The service // may be provided by AWS, an AWS Marketplace partner, or another AWS account. -// For more information, see VPC Endpoints (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-endpoints.html) +// For more information, see VPC Endpoints (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-endpoints.html) // in the Amazon Virtual Private Cloud User Guide. // // A gateway endpoint serves as a target for a route in your route table for @@ -6838,7 +5309,7 @@ const opCreateVpcEndpointConnectionNotification = "CreateVpcEndpointConnectionNo // CreateVpcEndpointConnectionNotificationRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpointConnectionNotification operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -6880,7 +5351,7 @@ func (c *EC2) CreateVpcEndpointConnectionNotificationRequest(input *CreateVpcEnd // Creates a connection notification for a specified VPC endpoint or VPC endpoint // service. A connection notification notifies you of specific endpoint events. // You must create an SNS topic to receive notifications. For more information, -// see Create a Topic (https://docs.aws.amazon.com/sns/latest/dg/CreateTopic.html) +// see Create a Topic (http://docs.aws.amazon.com/sns/latest/dg/CreateTopic.html) // in the Amazon Simple Notification Service Developer Guide. // // You can create a connection notification for interface endpoints only. @@ -6918,7 +5389,7 @@ const opCreateVpcEndpointServiceConfiguration = "CreateVpcEndpointServiceConfigu // CreateVpcEndpointServiceConfigurationRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcEndpointServiceConfiguration operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -6963,7 +5434,7 @@ func (c *EC2) CreateVpcEndpointServiceConfigurationRequest(input *CreateVpcEndpo // // To create an endpoint service configuration, you must first create a Network // Load Balancer for your service. For more information, see VPC Endpoint Services -// (https://docs.aws.amazon.com/vpc/latest/userguide/endpoint-service.html) +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/endpoint-service.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -6999,7 +5470,7 @@ const opCreateVpcPeeringConnection = "CreateVpcPeeringConnection" // CreateVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateVpcPeeringConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7045,7 +5516,7 @@ func (c *EC2) CreateVpcPeeringConnectionRequest(input *CreateVpcPeeringConnectio // CIDR blocks. // // Limitations and rules apply to a VPC peering connection. For more information, -// see the limitations (https://docs.aws.amazon.com/vpc/latest/peering/vpc-peering-basics.html#vpc-peering-limitations) +// see the limitations (http://docs.aws.amazon.com/AmazonVPC/latest/PeeringGuide/vpc-peering-basics.html#vpc-peering-limitations) // section in the VPC Peering Guide. // // The owner of the accepter VPC must accept the peering request to activate @@ -7088,7 +5559,7 @@ const opCreateVpnConnection = "CreateVpnConnection" // CreateVpnConnectionRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7128,7 +5599,7 @@ func (c *EC2) CreateVpnConnectionRequest(input *CreateVpnConnectionInput) (req * // CreateVpnConnection API operation for Amazon Elastic Compute Cloud. // // Creates a VPN connection between an existing virtual private gateway and -// a VPN customer gateway. The supported connection types is ipsec.1. +// a VPN customer gateway. The only supported connection type is ipsec.1. // // The response includes information that you need to give to your network administrator // to configure your customer gateway. @@ -7144,8 +5615,8 @@ func (c *EC2) CreateVpnConnectionRequest(input *CreateVpnConnectionInput) (req * // This is an idempotent operation. If you perform the operation more than once, // Amazon EC2 doesn't return an error. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information, see AWS Managed VPN Connections (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) +// in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -7180,7 +5651,7 @@ const opCreateVpnConnectionRoute = "CreateVpnConnectionRoute" // CreateVpnConnectionRouteRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnConnectionRoute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7214,7 +5685,8 @@ func (c *EC2) CreateVpnConnectionRouteRequest(input *CreateVpnConnectionRouteInp output = &CreateVpnConnectionRouteOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -7225,8 +5697,9 @@ func (c *EC2) CreateVpnConnectionRouteRequest(input *CreateVpnConnectionRouteInp // traffic to be routed from the virtual private gateway to the VPN customer // gateway. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about VPN connections, see AWS Managed VPN Connections +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) in the +// Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -7261,7 +5734,7 @@ const opCreateVpnGateway = "CreateVpnGateway" // CreateVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the CreateVpnGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7304,8 +5777,9 @@ func (c *EC2) CreateVpnGatewayRequest(input *CreateVpnGatewayInput) (req *reques // on the VPC side of your VPN connection. You can create a virtual private // gateway before creating the VPC itself. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about virtual private gateways, see AWS Managed VPN +// Connections (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) +// in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -7335,165 +5809,12 @@ func (c *EC2) CreateVpnGatewayWithContext(ctx aws.Context, input *CreateVpnGatew return out, req.Send() } -const opDeleteClientVpnEndpoint = "DeleteClientVpnEndpoint" - -// DeleteClientVpnEndpointRequest generates a "aws/request.Request" representing the -// client's request for the DeleteClientVpnEndpoint operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteClientVpnEndpoint for more information on using the DeleteClientVpnEndpoint -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteClientVpnEndpointRequest method. -// req, resp := client.DeleteClientVpnEndpointRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteClientVpnEndpoint -func (c *EC2) DeleteClientVpnEndpointRequest(input *DeleteClientVpnEndpointInput) (req *request.Request, output *DeleteClientVpnEndpointOutput) { - op := &request.Operation{ - Name: opDeleteClientVpnEndpoint, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteClientVpnEndpointInput{} - } - - output = &DeleteClientVpnEndpointOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteClientVpnEndpoint API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified Client VPN endpoint. You must disassociate all target -// networks before you can delete a Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteClientVpnEndpoint for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteClientVpnEndpoint -func (c *EC2) DeleteClientVpnEndpoint(input *DeleteClientVpnEndpointInput) (*DeleteClientVpnEndpointOutput, error) { - req, out := c.DeleteClientVpnEndpointRequest(input) - return out, req.Send() -} - -// DeleteClientVpnEndpointWithContext is the same as DeleteClientVpnEndpoint with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteClientVpnEndpoint for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteClientVpnEndpointWithContext(ctx aws.Context, input *DeleteClientVpnEndpointInput, opts ...request.Option) (*DeleteClientVpnEndpointOutput, error) { - req, out := c.DeleteClientVpnEndpointRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteClientVpnRoute = "DeleteClientVpnRoute" - -// DeleteClientVpnRouteRequest generates a "aws/request.Request" representing the -// client's request for the DeleteClientVpnRoute operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteClientVpnRoute for more information on using the DeleteClientVpnRoute -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteClientVpnRouteRequest method. -// req, resp := client.DeleteClientVpnRouteRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteClientVpnRoute -func (c *EC2) DeleteClientVpnRouteRequest(input *DeleteClientVpnRouteInput) (req *request.Request, output *DeleteClientVpnRouteOutput) { - op := &request.Operation{ - Name: opDeleteClientVpnRoute, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteClientVpnRouteInput{} - } - - output = &DeleteClientVpnRouteOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteClientVpnRoute API operation for Amazon Elastic Compute Cloud. -// -// Deletes a route from a Client VPN endpoint. You can only delete routes that -// you manually added using the CreateClientVpnRoute action. You cannot delete -// routes that were automatically added when associating a subnet. To remove -// routes that have been automatically added, disassociate the target subnet -// from the Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteClientVpnRoute for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteClientVpnRoute -func (c *EC2) DeleteClientVpnRoute(input *DeleteClientVpnRouteInput) (*DeleteClientVpnRouteOutput, error) { - req, out := c.DeleteClientVpnRouteRequest(input) - return out, req.Send() -} - -// DeleteClientVpnRouteWithContext is the same as DeleteClientVpnRoute with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteClientVpnRoute for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteClientVpnRouteWithContext(ctx aws.Context, input *DeleteClientVpnRouteInput, opts ...request.Option) (*DeleteClientVpnRouteOutput, error) { - req, out := c.DeleteClientVpnRouteRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDeleteCustomerGateway = "DeleteCustomerGateway" // DeleteCustomerGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteCustomerGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7527,7 +5848,8 @@ func (c *EC2) DeleteCustomerGatewayRequest(input *DeleteCustomerGatewayInput) (r output = &DeleteCustomerGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -7569,7 +5891,7 @@ const opDeleteDhcpOptions = "DeleteDhcpOptions" // DeleteDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the DeleteDhcpOptions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7603,7 +5925,8 @@ func (c *EC2) DeleteDhcpOptionsRequest(input *DeleteDhcpOptionsInput) (req *requ output = &DeleteDhcpOptionsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -7647,7 +5970,7 @@ const opDeleteEgressOnlyInternetGateway = "DeleteEgressOnlyInternetGateway" // DeleteEgressOnlyInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteEgressOnlyInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7721,7 +6044,7 @@ const opDeleteFleets = "DeleteFleets" // DeleteFleetsRequest generates a "aws/request.Request" representing the // client's request for the DeleteFleets operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7801,7 +6124,7 @@ const opDeleteFlowLogs = "DeleteFlowLogs" // DeleteFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the DeleteFlowLogs operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7875,7 +6198,7 @@ const opDeleteFpgaImage = "DeleteFpgaImage" // DeleteFpgaImageRequest generates a "aws/request.Request" representing the // client's request for the DeleteFpgaImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7949,7 +6272,7 @@ const opDeleteInternetGateway = "DeleteInternetGateway" // DeleteInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -7983,7 +6306,8 @@ func (c *EC2) DeleteInternetGatewayRequest(input *DeleteInternetGatewayInput) (r output = &DeleteInternetGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8025,7 +6349,7 @@ const opDeleteKeyPair = "DeleteKeyPair" // DeleteKeyPairRequest generates a "aws/request.Request" representing the // client's request for the DeleteKeyPair operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8059,7 +6383,8 @@ func (c *EC2) DeleteKeyPairRequest(input *DeleteKeyPairInput) (req *request.Requ output = &DeleteKeyPairOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8100,7 +6425,7 @@ const opDeleteLaunchTemplate = "DeleteLaunchTemplate" // DeleteLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the DeleteLaunchTemplate operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8175,7 +6500,7 @@ const opDeleteLaunchTemplateVersions = "DeleteLaunchTemplateVersions" // DeleteLaunchTemplateVersionsRequest generates a "aws/request.Request" representing the // client's request for the DeleteLaunchTemplateVersions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8252,7 +6577,7 @@ const opDeleteNatGateway = "DeleteNatGateway" // DeleteNatGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteNatGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8328,7 +6653,7 @@ const opDeleteNetworkAcl = "DeleteNetworkAcl" // DeleteNetworkAclRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkAcl operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8362,7 +6687,8 @@ func (c *EC2) DeleteNetworkAclRequest(input *DeleteNetworkAclInput) (req *reques output = &DeleteNetworkAclOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8404,7 +6730,7 @@ const opDeleteNetworkAclEntry = "DeleteNetworkAclEntry" // DeleteNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkAclEntry operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8438,7 +6764,8 @@ func (c *EC2) DeleteNetworkAclEntryRequest(input *DeleteNetworkAclEntryInput) (r output = &DeleteNetworkAclEntryOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8480,7 +6807,7 @@ const opDeleteNetworkInterface = "DeleteNetworkInterface" // DeleteNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkInterface operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8514,7 +6841,8 @@ func (c *EC2) DeleteNetworkInterfaceRequest(input *DeleteNetworkInterfaceInput) output = &DeleteNetworkInterfaceOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8556,7 +6884,7 @@ const opDeleteNetworkInterfacePermission = "DeleteNetworkInterfacePermission" // DeleteNetworkInterfacePermissionRequest generates a "aws/request.Request" representing the // client's request for the DeleteNetworkInterfacePermission operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8633,7 +6961,7 @@ const opDeletePlacementGroup = "DeletePlacementGroup" // DeletePlacementGroupRequest generates a "aws/request.Request" representing the // client's request for the DeletePlacementGroup operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8667,7 +6995,8 @@ func (c *EC2) DeletePlacementGroupRequest(input *DeletePlacementGroupInput) (req output = &DeletePlacementGroupOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8675,7 +7004,7 @@ func (c *EC2) DeletePlacementGroupRequest(input *DeletePlacementGroupInput) (req // // Deletes the specified placement group. You must terminate all instances in // the placement group before you can delete the placement group. For more information, -// see Placement Groups (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) +// see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -8711,7 +7040,7 @@ const opDeleteRoute = "DeleteRoute" // DeleteRouteRequest generates a "aws/request.Request" representing the // client's request for the DeleteRoute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8745,7 +7074,8 @@ func (c *EC2) DeleteRouteRequest(input *DeleteRouteInput) (req *request.Request, output = &DeleteRouteOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8786,7 +7116,7 @@ const opDeleteRouteTable = "DeleteRouteTable" // DeleteRouteTableRequest generates a "aws/request.Request" representing the // client's request for the DeleteRouteTable operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8820,7 +7150,8 @@ func (c *EC2) DeleteRouteTableRequest(input *DeleteRouteTableInput) (req *reques output = &DeleteRouteTableOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8863,7 +7194,7 @@ const opDeleteSecurityGroup = "DeleteSecurityGroup" // DeleteSecurityGroupRequest generates a "aws/request.Request" representing the // client's request for the DeleteSecurityGroup operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8897,7 +7228,8 @@ func (c *EC2) DeleteSecurityGroupRequest(input *DeleteSecurityGroupInput) (req * output = &DeleteSecurityGroupOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8942,7 +7274,7 @@ const opDeleteSnapshot = "DeleteSnapshot" // DeleteSnapshotRequest generates a "aws/request.Request" representing the // client's request for the DeleteSnapshot operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -8976,7 +7308,8 @@ func (c *EC2) DeleteSnapshotRequest(input *DeleteSnapshotInput) (req *request.Re output = &DeleteSnapshotOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -8995,7 +7328,7 @@ func (c *EC2) DeleteSnapshotRequest(input *DeleteSnapshotInput) (req *request.Re // a registered AMI. You must first de-register the AMI before you can delete // the snapshot. // -// For more information, see Deleting an Amazon EBS Snapshot (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-deleting-snapshot.html) +// For more information, see Deleting an Amazon EBS Snapshot (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-deleting-snapshot.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -9031,7 +7364,7 @@ const opDeleteSpotDatafeedSubscription = "DeleteSpotDatafeedSubscription" // DeleteSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DeleteSpotDatafeedSubscription operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -9065,7 +7398,8 @@ func (c *EC2) DeleteSpotDatafeedSubscriptionRequest(input *DeleteSpotDatafeedSub output = &DeleteSpotDatafeedSubscriptionOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -9106,7 +7440,7 @@ const opDeleteSubnet = "DeleteSubnet" // DeleteSubnetRequest generates a "aws/request.Request" representing the // client's request for the DeleteSubnet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -9140,7 +7474,8 @@ func (c *EC2) DeleteSubnetRequest(input *DeleteSubnetInput) (req *request.Reques output = &DeleteSubnetOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -9182,7 +7517,7 @@ const opDeleteTags = "DeleteTags" // DeleteTagsRequest generates a "aws/request.Request" representing the // client's request for the DeleteTags operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -9216,7 +7551,8 @@ func (c *EC2) DeleteTagsRequest(input *DeleteTagsInput) (req *request.Request, o output = &DeleteTagsOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -9225,7 +7561,7 @@ func (c *EC2) DeleteTagsRequest(input *DeleteTagsInput) (req *request.Request, o // Deletes the specified set of tags from the specified set of resources. // // To list the current tags, use DescribeTags. For more information about tags, -// see Tagging Your Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) +// see Tagging Your Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -9256,612 +7592,12 @@ func (c *EC2) DeleteTagsWithContext(ctx aws.Context, input *DeleteTagsInput, opt return out, req.Send() } -const opDeleteTrafficMirrorFilter = "DeleteTrafficMirrorFilter" - -// DeleteTrafficMirrorFilterRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTrafficMirrorFilter operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTrafficMirrorFilter for more information on using the DeleteTrafficMirrorFilter -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTrafficMirrorFilterRequest method. -// req, resp := client.DeleteTrafficMirrorFilterRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorFilter -func (c *EC2) DeleteTrafficMirrorFilterRequest(input *DeleteTrafficMirrorFilterInput) (req *request.Request, output *DeleteTrafficMirrorFilterOutput) { - op := &request.Operation{ - Name: opDeleteTrafficMirrorFilter, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTrafficMirrorFilterInput{} - } - - output = &DeleteTrafficMirrorFilterOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTrafficMirrorFilter API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified Traffic Mirror filter. -// -// You cannot delete a Traffic Mirror filter that is in use by a Traffic Mirror -// session. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTrafficMirrorFilter for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorFilter -func (c *EC2) DeleteTrafficMirrorFilter(input *DeleteTrafficMirrorFilterInput) (*DeleteTrafficMirrorFilterOutput, error) { - req, out := c.DeleteTrafficMirrorFilterRequest(input) - return out, req.Send() -} - -// DeleteTrafficMirrorFilterWithContext is the same as DeleteTrafficMirrorFilter with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTrafficMirrorFilter for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTrafficMirrorFilterWithContext(ctx aws.Context, input *DeleteTrafficMirrorFilterInput, opts ...request.Option) (*DeleteTrafficMirrorFilterOutput, error) { - req, out := c.DeleteTrafficMirrorFilterRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTrafficMirrorFilterRule = "DeleteTrafficMirrorFilterRule" - -// DeleteTrafficMirrorFilterRuleRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTrafficMirrorFilterRule operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTrafficMirrorFilterRule for more information on using the DeleteTrafficMirrorFilterRule -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTrafficMirrorFilterRuleRequest method. -// req, resp := client.DeleteTrafficMirrorFilterRuleRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorFilterRule -func (c *EC2) DeleteTrafficMirrorFilterRuleRequest(input *DeleteTrafficMirrorFilterRuleInput) (req *request.Request, output *DeleteTrafficMirrorFilterRuleOutput) { - op := &request.Operation{ - Name: opDeleteTrafficMirrorFilterRule, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTrafficMirrorFilterRuleInput{} - } - - output = &DeleteTrafficMirrorFilterRuleOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTrafficMirrorFilterRule API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified Traffic Mirror rule. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTrafficMirrorFilterRule for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorFilterRule -func (c *EC2) DeleteTrafficMirrorFilterRule(input *DeleteTrafficMirrorFilterRuleInput) (*DeleteTrafficMirrorFilterRuleOutput, error) { - req, out := c.DeleteTrafficMirrorFilterRuleRequest(input) - return out, req.Send() -} - -// DeleteTrafficMirrorFilterRuleWithContext is the same as DeleteTrafficMirrorFilterRule with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTrafficMirrorFilterRule for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTrafficMirrorFilterRuleWithContext(ctx aws.Context, input *DeleteTrafficMirrorFilterRuleInput, opts ...request.Option) (*DeleteTrafficMirrorFilterRuleOutput, error) { - req, out := c.DeleteTrafficMirrorFilterRuleRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTrafficMirrorSession = "DeleteTrafficMirrorSession" - -// DeleteTrafficMirrorSessionRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTrafficMirrorSession operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTrafficMirrorSession for more information on using the DeleteTrafficMirrorSession -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTrafficMirrorSessionRequest method. -// req, resp := client.DeleteTrafficMirrorSessionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorSession -func (c *EC2) DeleteTrafficMirrorSessionRequest(input *DeleteTrafficMirrorSessionInput) (req *request.Request, output *DeleteTrafficMirrorSessionOutput) { - op := &request.Operation{ - Name: opDeleteTrafficMirrorSession, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTrafficMirrorSessionInput{} - } - - output = &DeleteTrafficMirrorSessionOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTrafficMirrorSession API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified Traffic Mirror session. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTrafficMirrorSession for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorSession -func (c *EC2) DeleteTrafficMirrorSession(input *DeleteTrafficMirrorSessionInput) (*DeleteTrafficMirrorSessionOutput, error) { - req, out := c.DeleteTrafficMirrorSessionRequest(input) - return out, req.Send() -} - -// DeleteTrafficMirrorSessionWithContext is the same as DeleteTrafficMirrorSession with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTrafficMirrorSession for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTrafficMirrorSessionWithContext(ctx aws.Context, input *DeleteTrafficMirrorSessionInput, opts ...request.Option) (*DeleteTrafficMirrorSessionOutput, error) { - req, out := c.DeleteTrafficMirrorSessionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTrafficMirrorTarget = "DeleteTrafficMirrorTarget" - -// DeleteTrafficMirrorTargetRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTrafficMirrorTarget operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTrafficMirrorTarget for more information on using the DeleteTrafficMirrorTarget -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTrafficMirrorTargetRequest method. -// req, resp := client.DeleteTrafficMirrorTargetRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorTarget -func (c *EC2) DeleteTrafficMirrorTargetRequest(input *DeleteTrafficMirrorTargetInput) (req *request.Request, output *DeleteTrafficMirrorTargetOutput) { - op := &request.Operation{ - Name: opDeleteTrafficMirrorTarget, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTrafficMirrorTargetInput{} - } - - output = &DeleteTrafficMirrorTargetOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTrafficMirrorTarget API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified Traffic Mirror target. -// -// You cannot delete a Traffic Mirror target that is in use by a Traffic Mirror -// session. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTrafficMirrorTarget for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTrafficMirrorTarget -func (c *EC2) DeleteTrafficMirrorTarget(input *DeleteTrafficMirrorTargetInput) (*DeleteTrafficMirrorTargetOutput, error) { - req, out := c.DeleteTrafficMirrorTargetRequest(input) - return out, req.Send() -} - -// DeleteTrafficMirrorTargetWithContext is the same as DeleteTrafficMirrorTarget with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTrafficMirrorTarget for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTrafficMirrorTargetWithContext(ctx aws.Context, input *DeleteTrafficMirrorTargetInput, opts ...request.Option) (*DeleteTrafficMirrorTargetOutput, error) { - req, out := c.DeleteTrafficMirrorTargetRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTransitGateway = "DeleteTransitGateway" - -// DeleteTransitGatewayRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTransitGateway operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTransitGateway for more information on using the DeleteTransitGateway -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTransitGatewayRequest method. -// req, resp := client.DeleteTransitGatewayRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGateway -func (c *EC2) DeleteTransitGatewayRequest(input *DeleteTransitGatewayInput) (req *request.Request, output *DeleteTransitGatewayOutput) { - op := &request.Operation{ - Name: opDeleteTransitGateway, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTransitGatewayInput{} - } - - output = &DeleteTransitGatewayOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTransitGateway API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified transit gateway. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTransitGateway for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGateway -func (c *EC2) DeleteTransitGateway(input *DeleteTransitGatewayInput) (*DeleteTransitGatewayOutput, error) { - req, out := c.DeleteTransitGatewayRequest(input) - return out, req.Send() -} - -// DeleteTransitGatewayWithContext is the same as DeleteTransitGateway with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTransitGateway for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTransitGatewayWithContext(ctx aws.Context, input *DeleteTransitGatewayInput, opts ...request.Option) (*DeleteTransitGatewayOutput, error) { - req, out := c.DeleteTransitGatewayRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTransitGatewayRoute = "DeleteTransitGatewayRoute" - -// DeleteTransitGatewayRouteRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTransitGatewayRoute operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTransitGatewayRoute for more information on using the DeleteTransitGatewayRoute -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTransitGatewayRouteRequest method. -// req, resp := client.DeleteTransitGatewayRouteRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayRoute -func (c *EC2) DeleteTransitGatewayRouteRequest(input *DeleteTransitGatewayRouteInput) (req *request.Request, output *DeleteTransitGatewayRouteOutput) { - op := &request.Operation{ - Name: opDeleteTransitGatewayRoute, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTransitGatewayRouteInput{} - } - - output = &DeleteTransitGatewayRouteOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTransitGatewayRoute API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified route from the specified transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTransitGatewayRoute for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayRoute -func (c *EC2) DeleteTransitGatewayRoute(input *DeleteTransitGatewayRouteInput) (*DeleteTransitGatewayRouteOutput, error) { - req, out := c.DeleteTransitGatewayRouteRequest(input) - return out, req.Send() -} - -// DeleteTransitGatewayRouteWithContext is the same as DeleteTransitGatewayRoute with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTransitGatewayRoute for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTransitGatewayRouteWithContext(ctx aws.Context, input *DeleteTransitGatewayRouteInput, opts ...request.Option) (*DeleteTransitGatewayRouteOutput, error) { - req, out := c.DeleteTransitGatewayRouteRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTransitGatewayRouteTable = "DeleteTransitGatewayRouteTable" - -// DeleteTransitGatewayRouteTableRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTransitGatewayRouteTable operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTransitGatewayRouteTable for more information on using the DeleteTransitGatewayRouteTable -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTransitGatewayRouteTableRequest method. -// req, resp := client.DeleteTransitGatewayRouteTableRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayRouteTable -func (c *EC2) DeleteTransitGatewayRouteTableRequest(input *DeleteTransitGatewayRouteTableInput) (req *request.Request, output *DeleteTransitGatewayRouteTableOutput) { - op := &request.Operation{ - Name: opDeleteTransitGatewayRouteTable, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTransitGatewayRouteTableInput{} - } - - output = &DeleteTransitGatewayRouteTableOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTransitGatewayRouteTable API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified transit gateway route table. You must disassociate -// the route table from any transit gateway route tables before you can delete -// it. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTransitGatewayRouteTable for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayRouteTable -func (c *EC2) DeleteTransitGatewayRouteTable(input *DeleteTransitGatewayRouteTableInput) (*DeleteTransitGatewayRouteTableOutput, error) { - req, out := c.DeleteTransitGatewayRouteTableRequest(input) - return out, req.Send() -} - -// DeleteTransitGatewayRouteTableWithContext is the same as DeleteTransitGatewayRouteTable with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTransitGatewayRouteTable for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTransitGatewayRouteTableWithContext(ctx aws.Context, input *DeleteTransitGatewayRouteTableInput, opts ...request.Option) (*DeleteTransitGatewayRouteTableOutput, error) { - req, out := c.DeleteTransitGatewayRouteTableRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDeleteTransitGatewayVpcAttachment = "DeleteTransitGatewayVpcAttachment" - -// DeleteTransitGatewayVpcAttachmentRequest generates a "aws/request.Request" representing the -// client's request for the DeleteTransitGatewayVpcAttachment operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeleteTransitGatewayVpcAttachment for more information on using the DeleteTransitGatewayVpcAttachment -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeleteTransitGatewayVpcAttachmentRequest method. -// req, resp := client.DeleteTransitGatewayVpcAttachmentRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayVpcAttachment -func (c *EC2) DeleteTransitGatewayVpcAttachmentRequest(input *DeleteTransitGatewayVpcAttachmentInput) (req *request.Request, output *DeleteTransitGatewayVpcAttachmentOutput) { - op := &request.Operation{ - Name: opDeleteTransitGatewayVpcAttachment, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeleteTransitGatewayVpcAttachmentInput{} - } - - output = &DeleteTransitGatewayVpcAttachmentOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeleteTransitGatewayVpcAttachment API operation for Amazon Elastic Compute Cloud. -// -// Deletes the specified VPC attachment. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeleteTransitGatewayVpcAttachment for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteTransitGatewayVpcAttachment -func (c *EC2) DeleteTransitGatewayVpcAttachment(input *DeleteTransitGatewayVpcAttachmentInput) (*DeleteTransitGatewayVpcAttachmentOutput, error) { - req, out := c.DeleteTransitGatewayVpcAttachmentRequest(input) - return out, req.Send() -} - -// DeleteTransitGatewayVpcAttachmentWithContext is the same as DeleteTransitGatewayVpcAttachment with the addition of -// the ability to pass a context and additional request options. -// -// See DeleteTransitGatewayVpcAttachment for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeleteTransitGatewayVpcAttachmentWithContext(ctx aws.Context, input *DeleteTransitGatewayVpcAttachmentInput, opts ...request.Option) (*DeleteTransitGatewayVpcAttachmentOutput, error) { - req, out := c.DeleteTransitGatewayVpcAttachmentRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDeleteVolume = "DeleteVolume" // DeleteVolumeRequest generates a "aws/request.Request" representing the // client's request for the DeleteVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -9895,7 +7631,8 @@ func (c *EC2) DeleteVolumeRequest(input *DeleteVolumeInput) (req *request.Reques output = &DeleteVolumeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -9906,7 +7643,7 @@ func (c *EC2) DeleteVolumeRequest(input *DeleteVolumeInput) (req *request.Reques // // The volume can remain in the deleting state for several minutes. // -// For more information, see Deleting an Amazon EBS Volume (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-deleting-volume.html) +// For more information, see Deleting an Amazon EBS Volume (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-deleting-volume.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -9942,7 +7679,7 @@ const opDeleteVpc = "DeleteVpc" // DeleteVpcRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -9976,7 +7713,8 @@ func (c *EC2) DeleteVpcRequest(input *DeleteVpcInput) (req *request.Request, out output = &DeleteVpcOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -10021,7 +7759,7 @@ const opDeleteVpcEndpointConnectionNotifications = "DeleteVpcEndpointConnectionN // DeleteVpcEndpointConnectionNotificationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpointConnectionNotifications operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10095,7 +7833,7 @@ const opDeleteVpcEndpointServiceConfigurations = "DeleteVpcEndpointServiceConfig // DeleteVpcEndpointServiceConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpointServiceConfigurations operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10172,7 +7910,7 @@ const opDeleteVpcEndpoints = "DeleteVpcEndpoints" // DeleteVpcEndpointsRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcEndpoints operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10249,7 +7987,7 @@ const opDeleteVpcPeeringConnection = "DeleteVpcPeeringConnection" // DeleteVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpcPeeringConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10327,7 +8065,7 @@ const opDeleteVpnConnection = "DeleteVpnConnection" // DeleteVpnConnectionRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10361,7 +8099,8 @@ func (c *EC2) DeleteVpnConnectionRequest(input *DeleteVpnConnectionInput) (req * output = &DeleteVpnConnectionOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -10411,7 +8150,7 @@ const opDeleteVpnConnectionRoute = "DeleteVpnConnectionRoute" // DeleteVpnConnectionRouteRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnConnectionRoute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10445,7 +8184,8 @@ func (c *EC2) DeleteVpnConnectionRouteRequest(input *DeleteVpnConnectionRouteInp output = &DeleteVpnConnectionRouteOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -10489,7 +8229,7 @@ const opDeleteVpnGateway = "DeleteVpnGateway" // DeleteVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the DeleteVpnGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10523,7 +8263,8 @@ func (c *EC2) DeleteVpnGatewayRequest(input *DeleteVpnGatewayInput) (req *reques output = &DeleteVpnGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -10563,92 +8304,12 @@ func (c *EC2) DeleteVpnGatewayWithContext(ctx aws.Context, input *DeleteVpnGatew return out, req.Send() } -const opDeprovisionByoipCidr = "DeprovisionByoipCidr" - -// DeprovisionByoipCidrRequest generates a "aws/request.Request" representing the -// client's request for the DeprovisionByoipCidr operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DeprovisionByoipCidr for more information on using the DeprovisionByoipCidr -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DeprovisionByoipCidrRequest method. -// req, resp := client.DeprovisionByoipCidrRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeprovisionByoipCidr -func (c *EC2) DeprovisionByoipCidrRequest(input *DeprovisionByoipCidrInput) (req *request.Request, output *DeprovisionByoipCidrOutput) { - op := &request.Operation{ - Name: opDeprovisionByoipCidr, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DeprovisionByoipCidrInput{} - } - - output = &DeprovisionByoipCidrOutput{} - req = c.newRequest(op, input, output) - return -} - -// DeprovisionByoipCidr API operation for Amazon Elastic Compute Cloud. -// -// Releases the specified address range that you provisioned for use with your -// AWS resources through bring your own IP addresses (BYOIP) and deletes the -// corresponding address pool. -// -// Before you can release an address range, you must stop advertising it using -// WithdrawByoipCidr and you must not have any IP addresses allocated from its -// address range. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DeprovisionByoipCidr for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeprovisionByoipCidr -func (c *EC2) DeprovisionByoipCidr(input *DeprovisionByoipCidrInput) (*DeprovisionByoipCidrOutput, error) { - req, out := c.DeprovisionByoipCidrRequest(input) - return out, req.Send() -} - -// DeprovisionByoipCidrWithContext is the same as DeprovisionByoipCidr with the addition of -// the ability to pass a context and additional request options. -// -// See DeprovisionByoipCidr for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DeprovisionByoipCidrWithContext(ctx aws.Context, input *DeprovisionByoipCidrInput, opts ...request.Option) (*DeprovisionByoipCidrOutput, error) { - req, out := c.DeprovisionByoipCidrRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDeregisterImage = "DeregisterImage" // DeregisterImageRequest generates a "aws/request.Request" representing the // client's request for the DeregisterImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10682,7 +8343,8 @@ func (c *EC2) DeregisterImageRequest(input *DeregisterImageInput) (req *request. output = &DeregisterImageOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -10731,7 +8393,7 @@ const opDescribeAccountAttributes = "DescribeAccountAttributes" // DescribeAccountAttributesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAccountAttributes operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10823,7 +8485,7 @@ const opDescribeAddresses = "DescribeAddresses" // DescribeAddressesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAddresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10862,10 +8524,10 @@ func (c *EC2) DescribeAddressesRequest(input *DescribeAddressesInput) (req *requ // DescribeAddresses API operation for Amazon Elastic Compute Cloud. // -// Describes the specified Elastic IP addresses or all of your Elastic IP addresses. +// Describes one or more of your Elastic IP addresses. // // An Elastic IP address is for use in either the EC2-Classic platform or in -// a VPC. For more information, see Elastic IP Addresses (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) +// a VPC. For more information, see Elastic IP Addresses (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -10901,7 +8563,7 @@ const opDescribeAggregateIdFormat = "DescribeAggregateIdFormat" // DescribeAggregateIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeAggregateIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -10941,8 +8603,8 @@ func (c *EC2) DescribeAggregateIdFormatRequest(input *DescribeAggregateIdFormatI // DescribeAggregateIdFormat API operation for Amazon Elastic Compute Cloud. // // Describes the longer ID format settings for all resource types in a specific -// Region. This request is useful for performing a quick audit to determine -// whether a specific Region is fully opted in for longer IDs (17-character +// region. This request is useful for performing a quick audit to determine +// whether a specific region is fully opted in for longer IDs (17-character // IDs). // // This request only returns information about resource types that support longer @@ -10989,7 +8651,7 @@ const opDescribeAvailabilityZones = "DescribeAvailabilityZones" // DescribeAvailabilityZonesRequest generates a "aws/request.Request" representing the // client's request for the DescribeAvailabilityZones operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -11028,12 +8690,12 @@ func (c *EC2) DescribeAvailabilityZonesRequest(input *DescribeAvailabilityZonesI // DescribeAvailabilityZones API operation for Amazon Elastic Compute Cloud. // -// Describes the Availability Zones that are available to you. The results include -// zones only for the Region you're currently using. If there is an event impacting -// an Availability Zone, you can use this request to view the state and any -// provided message for that Availability Zone. +// Describes one or more of the Availability Zones that are available to you. +// The results include zones only for the region you're currently using. If +// there is an event impacting an Availability Zone, you can use this request +// to view the state and any provided message for that Availability Zone. // -// For more information, see Regions and Availability Zones (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html) +// For more information, see Regions and Availability Zones (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-regions-availability-zones.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -11069,7 +8731,7 @@ const opDescribeBundleTasks = "DescribeBundleTasks" // DescribeBundleTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeBundleTasks operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -11108,7 +8770,7 @@ func (c *EC2) DescribeBundleTasksRequest(input *DescribeBundleTasksInput) (req * // DescribeBundleTasks API operation for Amazon Elastic Compute Cloud. // -// Describes the specified bundle tasks or all of your bundle tasks. +// Describes one or more of your bundling tasks. // // Completed bundle tasks are listed for only a limited time. If your bundle // task is no longer in the list, you can still register an AMI from it. Just @@ -11143,276 +8805,12 @@ func (c *EC2) DescribeBundleTasksWithContext(ctx aws.Context, input *DescribeBun return out, req.Send() } -const opDescribeByoipCidrs = "DescribeByoipCidrs" - -// DescribeByoipCidrsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeByoipCidrs operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeByoipCidrs for more information on using the DescribeByoipCidrs -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeByoipCidrsRequest method. -// req, resp := client.DescribeByoipCidrsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeByoipCidrs -func (c *EC2) DescribeByoipCidrsRequest(input *DescribeByoipCidrsInput) (req *request.Request, output *DescribeByoipCidrsOutput) { - op := &request.Operation{ - Name: opDescribeByoipCidrs, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeByoipCidrsInput{} - } - - output = &DescribeByoipCidrsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeByoipCidrs API operation for Amazon Elastic Compute Cloud. -// -// Describes the IP address ranges that were specified in calls to ProvisionByoipCidr. -// -// To describe the address pools that were created when you provisioned the -// address ranges, use DescribePublicIpv4Pools. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeByoipCidrs for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeByoipCidrs -func (c *EC2) DescribeByoipCidrs(input *DescribeByoipCidrsInput) (*DescribeByoipCidrsOutput, error) { - req, out := c.DescribeByoipCidrsRequest(input) - return out, req.Send() -} - -// DescribeByoipCidrsWithContext is the same as DescribeByoipCidrs with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeByoipCidrs for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeByoipCidrsWithContext(ctx aws.Context, input *DescribeByoipCidrsInput, opts ...request.Option) (*DescribeByoipCidrsOutput, error) { - req, out := c.DescribeByoipCidrsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeByoipCidrsPages iterates over the pages of a DescribeByoipCidrs operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeByoipCidrs method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeByoipCidrs operation. -// pageNum := 0 -// err := client.DescribeByoipCidrsPages(params, -// func(page *ec2.DescribeByoipCidrsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeByoipCidrsPages(input *DescribeByoipCidrsInput, fn func(*DescribeByoipCidrsOutput, bool) bool) error { - return c.DescribeByoipCidrsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeByoipCidrsPagesWithContext same as DescribeByoipCidrsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeByoipCidrsPagesWithContext(ctx aws.Context, input *DescribeByoipCidrsInput, fn func(*DescribeByoipCidrsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeByoipCidrsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeByoipCidrsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeByoipCidrsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeCapacityReservations = "DescribeCapacityReservations" - -// DescribeCapacityReservationsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeCapacityReservations operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeCapacityReservations for more information on using the DescribeCapacityReservations -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeCapacityReservationsRequest method. -// req, resp := client.DescribeCapacityReservationsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeCapacityReservations -func (c *EC2) DescribeCapacityReservationsRequest(input *DescribeCapacityReservationsInput) (req *request.Request, output *DescribeCapacityReservationsOutput) { - op := &request.Operation{ - Name: opDescribeCapacityReservations, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeCapacityReservationsInput{} - } - - output = &DescribeCapacityReservationsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeCapacityReservations API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more of your Capacity Reservations. The results describe -// only the Capacity Reservations in the AWS Region that you're currently using. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeCapacityReservations for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeCapacityReservations -func (c *EC2) DescribeCapacityReservations(input *DescribeCapacityReservationsInput) (*DescribeCapacityReservationsOutput, error) { - req, out := c.DescribeCapacityReservationsRequest(input) - return out, req.Send() -} - -// DescribeCapacityReservationsWithContext is the same as DescribeCapacityReservations with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeCapacityReservations for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeCapacityReservationsWithContext(ctx aws.Context, input *DescribeCapacityReservationsInput, opts ...request.Option) (*DescribeCapacityReservationsOutput, error) { - req, out := c.DescribeCapacityReservationsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeCapacityReservationsPages iterates over the pages of a DescribeCapacityReservations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeCapacityReservations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeCapacityReservations operation. -// pageNum := 0 -// err := client.DescribeCapacityReservationsPages(params, -// func(page *ec2.DescribeCapacityReservationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeCapacityReservationsPages(input *DescribeCapacityReservationsInput, fn func(*DescribeCapacityReservationsOutput, bool) bool) error { - return c.DescribeCapacityReservationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeCapacityReservationsPagesWithContext same as DescribeCapacityReservationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeCapacityReservationsPagesWithContext(ctx aws.Context, input *DescribeCapacityReservationsInput, fn func(*DescribeCapacityReservationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeCapacityReservationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeCapacityReservationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeCapacityReservationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeClassicLinkInstances = "DescribeClassicLinkInstances" // DescribeClassicLinkInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeClassicLinkInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -11438,12 +8836,6 @@ func (c *EC2) DescribeClassicLinkInstancesRequest(input *DescribeClassicLinkInst Name: opDescribeClassicLinkInstances, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -11490,713 +8882,12 @@ func (c *EC2) DescribeClassicLinkInstancesWithContext(ctx aws.Context, input *De return out, req.Send() } -// DescribeClassicLinkInstancesPages iterates over the pages of a DescribeClassicLinkInstances operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClassicLinkInstances method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClassicLinkInstances operation. -// pageNum := 0 -// err := client.DescribeClassicLinkInstancesPages(params, -// func(page *ec2.DescribeClassicLinkInstancesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClassicLinkInstancesPages(input *DescribeClassicLinkInstancesInput, fn func(*DescribeClassicLinkInstancesOutput, bool) bool) error { - return c.DescribeClassicLinkInstancesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClassicLinkInstancesPagesWithContext same as DescribeClassicLinkInstancesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClassicLinkInstancesPagesWithContext(ctx aws.Context, input *DescribeClassicLinkInstancesInput, fn func(*DescribeClassicLinkInstancesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClassicLinkInstancesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClassicLinkInstancesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClassicLinkInstancesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeClientVpnAuthorizationRules = "DescribeClientVpnAuthorizationRules" - -// DescribeClientVpnAuthorizationRulesRequest generates a "aws/request.Request" representing the -// client's request for the DescribeClientVpnAuthorizationRules operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeClientVpnAuthorizationRules for more information on using the DescribeClientVpnAuthorizationRules -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeClientVpnAuthorizationRulesRequest method. -// req, resp := client.DescribeClientVpnAuthorizationRulesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnAuthorizationRules -func (c *EC2) DescribeClientVpnAuthorizationRulesRequest(input *DescribeClientVpnAuthorizationRulesInput) (req *request.Request, output *DescribeClientVpnAuthorizationRulesOutput) { - op := &request.Operation{ - Name: opDescribeClientVpnAuthorizationRules, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeClientVpnAuthorizationRulesInput{} - } - - output = &DescribeClientVpnAuthorizationRulesOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeClientVpnAuthorizationRules API operation for Amazon Elastic Compute Cloud. -// -// Describes the authorization rules for a specified Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeClientVpnAuthorizationRules for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnAuthorizationRules -func (c *EC2) DescribeClientVpnAuthorizationRules(input *DescribeClientVpnAuthorizationRulesInput) (*DescribeClientVpnAuthorizationRulesOutput, error) { - req, out := c.DescribeClientVpnAuthorizationRulesRequest(input) - return out, req.Send() -} - -// DescribeClientVpnAuthorizationRulesWithContext is the same as DescribeClientVpnAuthorizationRules with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeClientVpnAuthorizationRules for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnAuthorizationRulesWithContext(ctx aws.Context, input *DescribeClientVpnAuthorizationRulesInput, opts ...request.Option) (*DescribeClientVpnAuthorizationRulesOutput, error) { - req, out := c.DescribeClientVpnAuthorizationRulesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeClientVpnAuthorizationRulesPages iterates over the pages of a DescribeClientVpnAuthorizationRules operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClientVpnAuthorizationRules method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClientVpnAuthorizationRules operation. -// pageNum := 0 -// err := client.DescribeClientVpnAuthorizationRulesPages(params, -// func(page *ec2.DescribeClientVpnAuthorizationRulesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClientVpnAuthorizationRulesPages(input *DescribeClientVpnAuthorizationRulesInput, fn func(*DescribeClientVpnAuthorizationRulesOutput, bool) bool) error { - return c.DescribeClientVpnAuthorizationRulesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClientVpnAuthorizationRulesPagesWithContext same as DescribeClientVpnAuthorizationRulesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnAuthorizationRulesPagesWithContext(ctx aws.Context, input *DescribeClientVpnAuthorizationRulesInput, fn func(*DescribeClientVpnAuthorizationRulesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClientVpnAuthorizationRulesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClientVpnAuthorizationRulesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClientVpnAuthorizationRulesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeClientVpnConnections = "DescribeClientVpnConnections" - -// DescribeClientVpnConnectionsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeClientVpnConnections operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeClientVpnConnections for more information on using the DescribeClientVpnConnections -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeClientVpnConnectionsRequest method. -// req, resp := client.DescribeClientVpnConnectionsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnConnections -func (c *EC2) DescribeClientVpnConnectionsRequest(input *DescribeClientVpnConnectionsInput) (req *request.Request, output *DescribeClientVpnConnectionsOutput) { - op := &request.Operation{ - Name: opDescribeClientVpnConnections, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeClientVpnConnectionsInput{} - } - - output = &DescribeClientVpnConnectionsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeClientVpnConnections API operation for Amazon Elastic Compute Cloud. -// -// Describes active client connections and connections that have been terminated -// within the last 60 minutes for the specified Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeClientVpnConnections for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnConnections -func (c *EC2) DescribeClientVpnConnections(input *DescribeClientVpnConnectionsInput) (*DescribeClientVpnConnectionsOutput, error) { - req, out := c.DescribeClientVpnConnectionsRequest(input) - return out, req.Send() -} - -// DescribeClientVpnConnectionsWithContext is the same as DescribeClientVpnConnections with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeClientVpnConnections for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnConnectionsWithContext(ctx aws.Context, input *DescribeClientVpnConnectionsInput, opts ...request.Option) (*DescribeClientVpnConnectionsOutput, error) { - req, out := c.DescribeClientVpnConnectionsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeClientVpnConnectionsPages iterates over the pages of a DescribeClientVpnConnections operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClientVpnConnections method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClientVpnConnections operation. -// pageNum := 0 -// err := client.DescribeClientVpnConnectionsPages(params, -// func(page *ec2.DescribeClientVpnConnectionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClientVpnConnectionsPages(input *DescribeClientVpnConnectionsInput, fn func(*DescribeClientVpnConnectionsOutput, bool) bool) error { - return c.DescribeClientVpnConnectionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClientVpnConnectionsPagesWithContext same as DescribeClientVpnConnectionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnConnectionsPagesWithContext(ctx aws.Context, input *DescribeClientVpnConnectionsInput, fn func(*DescribeClientVpnConnectionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClientVpnConnectionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClientVpnConnectionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClientVpnConnectionsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeClientVpnEndpoints = "DescribeClientVpnEndpoints" - -// DescribeClientVpnEndpointsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeClientVpnEndpoints operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeClientVpnEndpoints for more information on using the DescribeClientVpnEndpoints -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeClientVpnEndpointsRequest method. -// req, resp := client.DescribeClientVpnEndpointsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnEndpoints -func (c *EC2) DescribeClientVpnEndpointsRequest(input *DescribeClientVpnEndpointsInput) (req *request.Request, output *DescribeClientVpnEndpointsOutput) { - op := &request.Operation{ - Name: opDescribeClientVpnEndpoints, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeClientVpnEndpointsInput{} - } - - output = &DescribeClientVpnEndpointsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeClientVpnEndpoints API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more Client VPN endpoints in the account. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeClientVpnEndpoints for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnEndpoints -func (c *EC2) DescribeClientVpnEndpoints(input *DescribeClientVpnEndpointsInput) (*DescribeClientVpnEndpointsOutput, error) { - req, out := c.DescribeClientVpnEndpointsRequest(input) - return out, req.Send() -} - -// DescribeClientVpnEndpointsWithContext is the same as DescribeClientVpnEndpoints with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeClientVpnEndpoints for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnEndpointsWithContext(ctx aws.Context, input *DescribeClientVpnEndpointsInput, opts ...request.Option) (*DescribeClientVpnEndpointsOutput, error) { - req, out := c.DescribeClientVpnEndpointsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeClientVpnEndpointsPages iterates over the pages of a DescribeClientVpnEndpoints operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClientVpnEndpoints method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClientVpnEndpoints operation. -// pageNum := 0 -// err := client.DescribeClientVpnEndpointsPages(params, -// func(page *ec2.DescribeClientVpnEndpointsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClientVpnEndpointsPages(input *DescribeClientVpnEndpointsInput, fn func(*DescribeClientVpnEndpointsOutput, bool) bool) error { - return c.DescribeClientVpnEndpointsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClientVpnEndpointsPagesWithContext same as DescribeClientVpnEndpointsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnEndpointsPagesWithContext(ctx aws.Context, input *DescribeClientVpnEndpointsInput, fn func(*DescribeClientVpnEndpointsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClientVpnEndpointsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClientVpnEndpointsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClientVpnEndpointsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeClientVpnRoutes = "DescribeClientVpnRoutes" - -// DescribeClientVpnRoutesRequest generates a "aws/request.Request" representing the -// client's request for the DescribeClientVpnRoutes operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeClientVpnRoutes for more information on using the DescribeClientVpnRoutes -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeClientVpnRoutesRequest method. -// req, resp := client.DescribeClientVpnRoutesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnRoutes -func (c *EC2) DescribeClientVpnRoutesRequest(input *DescribeClientVpnRoutesInput) (req *request.Request, output *DescribeClientVpnRoutesOutput) { - op := &request.Operation{ - Name: opDescribeClientVpnRoutes, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeClientVpnRoutesInput{} - } - - output = &DescribeClientVpnRoutesOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeClientVpnRoutes API operation for Amazon Elastic Compute Cloud. -// -// Describes the routes for the specified Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeClientVpnRoutes for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnRoutes -func (c *EC2) DescribeClientVpnRoutes(input *DescribeClientVpnRoutesInput) (*DescribeClientVpnRoutesOutput, error) { - req, out := c.DescribeClientVpnRoutesRequest(input) - return out, req.Send() -} - -// DescribeClientVpnRoutesWithContext is the same as DescribeClientVpnRoutes with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeClientVpnRoutes for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnRoutesWithContext(ctx aws.Context, input *DescribeClientVpnRoutesInput, opts ...request.Option) (*DescribeClientVpnRoutesOutput, error) { - req, out := c.DescribeClientVpnRoutesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeClientVpnRoutesPages iterates over the pages of a DescribeClientVpnRoutes operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClientVpnRoutes method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClientVpnRoutes operation. -// pageNum := 0 -// err := client.DescribeClientVpnRoutesPages(params, -// func(page *ec2.DescribeClientVpnRoutesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClientVpnRoutesPages(input *DescribeClientVpnRoutesInput, fn func(*DescribeClientVpnRoutesOutput, bool) bool) error { - return c.DescribeClientVpnRoutesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClientVpnRoutesPagesWithContext same as DescribeClientVpnRoutesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnRoutesPagesWithContext(ctx aws.Context, input *DescribeClientVpnRoutesInput, fn func(*DescribeClientVpnRoutesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClientVpnRoutesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClientVpnRoutesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClientVpnRoutesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeClientVpnTargetNetworks = "DescribeClientVpnTargetNetworks" - -// DescribeClientVpnTargetNetworksRequest generates a "aws/request.Request" representing the -// client's request for the DescribeClientVpnTargetNetworks operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeClientVpnTargetNetworks for more information on using the DescribeClientVpnTargetNetworks -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeClientVpnTargetNetworksRequest method. -// req, resp := client.DescribeClientVpnTargetNetworksRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnTargetNetworks -func (c *EC2) DescribeClientVpnTargetNetworksRequest(input *DescribeClientVpnTargetNetworksInput) (req *request.Request, output *DescribeClientVpnTargetNetworksOutput) { - op := &request.Operation{ - Name: opDescribeClientVpnTargetNetworks, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeClientVpnTargetNetworksInput{} - } - - output = &DescribeClientVpnTargetNetworksOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeClientVpnTargetNetworks API operation for Amazon Elastic Compute Cloud. -// -// Describes the target networks associated with the specified Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeClientVpnTargetNetworks for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeClientVpnTargetNetworks -func (c *EC2) DescribeClientVpnTargetNetworks(input *DescribeClientVpnTargetNetworksInput) (*DescribeClientVpnTargetNetworksOutput, error) { - req, out := c.DescribeClientVpnTargetNetworksRequest(input) - return out, req.Send() -} - -// DescribeClientVpnTargetNetworksWithContext is the same as DescribeClientVpnTargetNetworks with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeClientVpnTargetNetworks for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnTargetNetworksWithContext(ctx aws.Context, input *DescribeClientVpnTargetNetworksInput, opts ...request.Option) (*DescribeClientVpnTargetNetworksOutput, error) { - req, out := c.DescribeClientVpnTargetNetworksRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeClientVpnTargetNetworksPages iterates over the pages of a DescribeClientVpnTargetNetworks operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeClientVpnTargetNetworks method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeClientVpnTargetNetworks operation. -// pageNum := 0 -// err := client.DescribeClientVpnTargetNetworksPages(params, -// func(page *ec2.DescribeClientVpnTargetNetworksOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeClientVpnTargetNetworksPages(input *DescribeClientVpnTargetNetworksInput, fn func(*DescribeClientVpnTargetNetworksOutput, bool) bool) error { - return c.DescribeClientVpnTargetNetworksPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeClientVpnTargetNetworksPagesWithContext same as DescribeClientVpnTargetNetworksPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeClientVpnTargetNetworksPagesWithContext(ctx aws.Context, input *DescribeClientVpnTargetNetworksInput, fn func(*DescribeClientVpnTargetNetworksOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeClientVpnTargetNetworksInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeClientVpnTargetNetworksRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeClientVpnTargetNetworksOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeConversionTasks = "DescribeConversionTasks" // DescribeConversionTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeConversionTasks operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12235,11 +8926,11 @@ func (c *EC2) DescribeConversionTasksRequest(input *DescribeConversionTasksInput // DescribeConversionTasks API operation for Amazon Elastic Compute Cloud. // -// Describes the specified conversion tasks or all your conversion tasks. For -// more information, see the VM Import/Export User Guide (https://docs.aws.amazon.com/vm-import/latest/userguide/). +// Describes one or more of your conversion tasks. For more information, see +// the VM Import/Export User Guide (http://docs.aws.amazon.com/vm-import/latest/userguide/). // // For information about the import manifest referenced by this API action, -// see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). +// see VM Import Manifest (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12274,7 +8965,7 @@ const opDescribeCustomerGateways = "DescribeCustomerGateways" // DescribeCustomerGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeCustomerGateways operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12315,8 +9006,9 @@ func (c *EC2) DescribeCustomerGatewaysRequest(input *DescribeCustomerGatewaysInp // // Describes one or more of your VPN customer gateways. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about VPN customer gateways, see AWS Managed VPN Connections +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) in the +// Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12351,7 +9043,7 @@ const opDescribeDhcpOptions = "DescribeDhcpOptions" // DescribeDhcpOptionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeDhcpOptions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12377,12 +9069,6 @@ func (c *EC2) DescribeDhcpOptionsRequest(input *DescribeDhcpOptionsInput) (req * Name: opDescribeDhcpOptions, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -12398,7 +9084,7 @@ func (c *EC2) DescribeDhcpOptionsRequest(input *DescribeDhcpOptionsInput) (req * // // Describes one or more of your DHCP options sets. // -// For more information, see DHCP Options Sets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_DHCP_Options.html) +// For more information, see DHCP Options Sets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_DHCP_Options.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -12429,62 +9115,12 @@ func (c *EC2) DescribeDhcpOptionsWithContext(ctx aws.Context, input *DescribeDhc return out, req.Send() } -// DescribeDhcpOptionsPages iterates over the pages of a DescribeDhcpOptions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeDhcpOptions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeDhcpOptions operation. -// pageNum := 0 -// err := client.DescribeDhcpOptionsPages(params, -// func(page *ec2.DescribeDhcpOptionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeDhcpOptionsPages(input *DescribeDhcpOptionsInput, fn func(*DescribeDhcpOptionsOutput, bool) bool) error { - return c.DescribeDhcpOptionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeDhcpOptionsPagesWithContext same as DescribeDhcpOptionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeDhcpOptionsPagesWithContext(ctx aws.Context, input *DescribeDhcpOptionsInput, fn func(*DescribeDhcpOptionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeDhcpOptionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeDhcpOptionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeDhcpOptionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeEgressOnlyInternetGateways = "DescribeEgressOnlyInternetGateways" // DescribeEgressOnlyInternetGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeEgressOnlyInternetGateways operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12510,12 +9146,6 @@ func (c *EC2) DescribeEgressOnlyInternetGatewaysRequest(input *DescribeEgressOnl Name: opDescribeEgressOnlyInternetGateways, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -12559,62 +9189,12 @@ func (c *EC2) DescribeEgressOnlyInternetGatewaysWithContext(ctx aws.Context, inp return out, req.Send() } -// DescribeEgressOnlyInternetGatewaysPages iterates over the pages of a DescribeEgressOnlyInternetGateways operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeEgressOnlyInternetGateways method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeEgressOnlyInternetGateways operation. -// pageNum := 0 -// err := client.DescribeEgressOnlyInternetGatewaysPages(params, -// func(page *ec2.DescribeEgressOnlyInternetGatewaysOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeEgressOnlyInternetGatewaysPages(input *DescribeEgressOnlyInternetGatewaysInput, fn func(*DescribeEgressOnlyInternetGatewaysOutput, bool) bool) error { - return c.DescribeEgressOnlyInternetGatewaysPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeEgressOnlyInternetGatewaysPagesWithContext same as DescribeEgressOnlyInternetGatewaysPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeEgressOnlyInternetGatewaysPagesWithContext(ctx aws.Context, input *DescribeEgressOnlyInternetGatewaysInput, fn func(*DescribeEgressOnlyInternetGatewaysOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeEgressOnlyInternetGatewaysInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeEgressOnlyInternetGatewaysRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeEgressOnlyInternetGatewaysOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeElasticGpus = "DescribeElasticGpus" // DescribeElasticGpusRequest generates a "aws/request.Request" representing the // client's request for the DescribeElasticGpus operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12653,9 +9233,8 @@ func (c *EC2) DescribeElasticGpusRequest(input *DescribeElasticGpusInput) (req * // DescribeElasticGpus API operation for Amazon Elastic Compute Cloud. // -// Describes the Elastic Graphics accelerator associated with your instances. -// For more information about Elastic Graphics, see Amazon Elastic Graphics -// (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/elastic-graphics.html). +// Describes the Elastic GPUs associated with your instances. For more information +// about Elastic GPUs, see Amazon EC2 Elastic GPUs (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/elastic-gpus.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12690,7 +9269,7 @@ const opDescribeExportTasks = "DescribeExportTasks" // DescribeExportTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeExportTasks operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12729,7 +9308,7 @@ func (c *EC2) DescribeExportTasksRequest(input *DescribeExportTasksInput) (req * // DescribeExportTasks API operation for Amazon Elastic Compute Cloud. // -// Describes the specified export tasks or all your export tasks. +// Describes one or more of your export tasks. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12764,7 +9343,7 @@ const opDescribeFleetHistory = "DescribeFleetHistory" // DescribeFleetHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetHistory operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12838,7 +9417,7 @@ const opDescribeFleetInstances = "DescribeFleetInstances" // DescribeFleetInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleetInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12912,7 +9491,7 @@ const opDescribeFleets = "DescribeFleets" // DescribeFleetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFleets operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -12938,12 +9517,6 @@ func (c *EC2) DescribeFleetsRequest(input *DescribeFleetsInput) (req *request.Re Name: opDescribeFleets, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -12957,7 +9530,7 @@ func (c *EC2) DescribeFleetsRequest(input *DescribeFleetsInput) (req *request.Re // DescribeFleets API operation for Amazon Elastic Compute Cloud. // -// Describes the specified EC2 Fleets or all your EC2 Fleets. +// Describes one or more of your EC2 Fleet. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -12987,62 +9560,12 @@ func (c *EC2) DescribeFleetsWithContext(ctx aws.Context, input *DescribeFleetsIn return out, req.Send() } -// DescribeFleetsPages iterates over the pages of a DescribeFleets operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeFleets method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeFleets operation. -// pageNum := 0 -// err := client.DescribeFleetsPages(params, -// func(page *ec2.DescribeFleetsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeFleetsPages(input *DescribeFleetsInput, fn func(*DescribeFleetsOutput, bool) bool) error { - return c.DescribeFleetsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeFleetsPagesWithContext same as DescribeFleetsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeFleetsPagesWithContext(ctx aws.Context, input *DescribeFleetsInput, fn func(*DescribeFleetsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeFleetsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeFleetsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeFleetsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeFlowLogs = "DescribeFlowLogs" // DescribeFlowLogsRequest generates a "aws/request.Request" representing the // client's request for the DescribeFlowLogs operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13068,12 +9591,6 @@ func (c *EC2) DescribeFlowLogsRequest(input *DescribeFlowLogsInput) (req *reques Name: opDescribeFlowLogs, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13119,62 +9636,12 @@ func (c *EC2) DescribeFlowLogsWithContext(ctx aws.Context, input *DescribeFlowLo return out, req.Send() } -// DescribeFlowLogsPages iterates over the pages of a DescribeFlowLogs operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeFlowLogs method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeFlowLogs operation. -// pageNum := 0 -// err := client.DescribeFlowLogsPages(params, -// func(page *ec2.DescribeFlowLogsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeFlowLogsPages(input *DescribeFlowLogsInput, fn func(*DescribeFlowLogsOutput, bool) bool) error { - return c.DescribeFlowLogsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeFlowLogsPagesWithContext same as DescribeFlowLogsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeFlowLogsPagesWithContext(ctx aws.Context, input *DescribeFlowLogsInput, fn func(*DescribeFlowLogsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeFlowLogsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeFlowLogsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeFlowLogsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeFpgaImageAttribute = "DescribeFpgaImageAttribute" // DescribeFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeFpgaImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13248,7 +9715,7 @@ const opDescribeFpgaImages = "DescribeFpgaImages" // DescribeFpgaImagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeFpgaImages operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13274,12 +9741,6 @@ func (c *EC2) DescribeFpgaImagesRequest(input *DescribeFpgaImagesInput) (req *re Name: opDescribeFpgaImages, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13293,9 +9754,9 @@ func (c *EC2) DescribeFpgaImagesRequest(input *DescribeFpgaImagesInput) (req *re // DescribeFpgaImages API operation for Amazon Elastic Compute Cloud. // -// Describes the Amazon FPGA Images (AFIs) available to you. These include public -// AFIs, private AFIs that you own, and AFIs owned by other AWS accounts for -// which you have load permissions. +// Describes one or more available Amazon FPGA Images (AFIs). These include +// public AFIs, private AFIs that you own, and AFIs owned by other AWS accounts +// for which you have load permissions. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -13325,62 +9786,12 @@ func (c *EC2) DescribeFpgaImagesWithContext(ctx aws.Context, input *DescribeFpga return out, req.Send() } -// DescribeFpgaImagesPages iterates over the pages of a DescribeFpgaImages operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeFpgaImages method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeFpgaImages operation. -// pageNum := 0 -// err := client.DescribeFpgaImagesPages(params, -// func(page *ec2.DescribeFpgaImagesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeFpgaImagesPages(input *DescribeFpgaImagesInput, fn func(*DescribeFpgaImagesOutput, bool) bool) error { - return c.DescribeFpgaImagesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeFpgaImagesPagesWithContext same as DescribeFpgaImagesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeFpgaImagesPagesWithContext(ctx aws.Context, input *DescribeFpgaImagesInput, fn func(*DescribeFpgaImagesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeFpgaImagesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeFpgaImagesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeFpgaImagesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeHostReservationOfferings = "DescribeHostReservationOfferings" // DescribeHostReservationOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHostReservationOfferings operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13406,12 +9817,6 @@ func (c *EC2) DescribeHostReservationOfferingsRequest(input *DescribeHostReserva Name: opDescribeHostReservationOfferings, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13428,11 +9833,11 @@ func (c *EC2) DescribeHostReservationOfferingsRequest(input *DescribeHostReserva // Describes the Dedicated Host reservations that are available to purchase. // // The results describe all the Dedicated Host reservation offerings, including -// offerings that may not match the instance family and Region of your Dedicated +// offerings that may not match the instance family and region of your Dedicated // Hosts. When purchasing an offering, ensure that the instance family and Region // of the offering matches that of the Dedicated Hosts with which it is to be -// associated. For more information about supported instance types, see Dedicated -// Hosts Overview (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-overview.html) +// associated . For more information about supported instance types, see Dedicated +// Hosts Overview (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-overview.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -13463,62 +9868,12 @@ func (c *EC2) DescribeHostReservationOfferingsWithContext(ctx aws.Context, input return out, req.Send() } -// DescribeHostReservationOfferingsPages iterates over the pages of a DescribeHostReservationOfferings operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeHostReservationOfferings method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeHostReservationOfferings operation. -// pageNum := 0 -// err := client.DescribeHostReservationOfferingsPages(params, -// func(page *ec2.DescribeHostReservationOfferingsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeHostReservationOfferingsPages(input *DescribeHostReservationOfferingsInput, fn func(*DescribeHostReservationOfferingsOutput, bool) bool) error { - return c.DescribeHostReservationOfferingsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeHostReservationOfferingsPagesWithContext same as DescribeHostReservationOfferingsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeHostReservationOfferingsPagesWithContext(ctx aws.Context, input *DescribeHostReservationOfferingsInput, fn func(*DescribeHostReservationOfferingsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeHostReservationOfferingsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeHostReservationOfferingsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeHostReservationOfferingsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeHostReservations = "DescribeHostReservations" // DescribeHostReservationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHostReservations operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13544,12 +9899,6 @@ func (c *EC2) DescribeHostReservationsRequest(input *DescribeHostReservationsInp Name: opDescribeHostReservations, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13593,62 +9942,12 @@ func (c *EC2) DescribeHostReservationsWithContext(ctx aws.Context, input *Descri return out, req.Send() } -// DescribeHostReservationsPages iterates over the pages of a DescribeHostReservations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeHostReservations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeHostReservations operation. -// pageNum := 0 -// err := client.DescribeHostReservationsPages(params, -// func(page *ec2.DescribeHostReservationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeHostReservationsPages(input *DescribeHostReservationsInput, fn func(*DescribeHostReservationsOutput, bool) bool) error { - return c.DescribeHostReservationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeHostReservationsPagesWithContext same as DescribeHostReservationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeHostReservationsPagesWithContext(ctx aws.Context, input *DescribeHostReservationsInput, fn func(*DescribeHostReservationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeHostReservationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeHostReservationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeHostReservationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeHosts = "DescribeHosts" // DescribeHostsRequest generates a "aws/request.Request" representing the // client's request for the DescribeHosts operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13674,12 +9973,6 @@ func (c *EC2) DescribeHostsRequest(input *DescribeHostsInput) (req *request.Requ Name: opDescribeHosts, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13693,9 +9986,9 @@ func (c *EC2) DescribeHostsRequest(input *DescribeHostsInput) (req *request.Requ // DescribeHosts API operation for Amazon Elastic Compute Cloud. // -// Describes the specified Dedicated Hosts or all your Dedicated Hosts. +// Describes one or more of your Dedicated Hosts. // -// The results describe only the Dedicated Hosts in the Region you're currently +// The results describe only the Dedicated Hosts in the region you're currently // using. All listed instances consume capacity on your Dedicated Host. Dedicated // Hosts that have recently been released are listed with the state released. // @@ -13727,62 +10020,12 @@ func (c *EC2) DescribeHostsWithContext(ctx aws.Context, input *DescribeHostsInpu return out, req.Send() } -// DescribeHostsPages iterates over the pages of a DescribeHosts operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeHosts method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeHosts operation. -// pageNum := 0 -// err := client.DescribeHostsPages(params, -// func(page *ec2.DescribeHostsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeHostsPages(input *DescribeHostsInput, fn func(*DescribeHostsOutput, bool) bool) error { - return c.DescribeHostsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeHostsPagesWithContext same as DescribeHostsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeHostsPagesWithContext(ctx aws.Context, input *DescribeHostsInput, fn func(*DescribeHostsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeHostsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeHostsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeHostsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeIamInstanceProfileAssociations = "DescribeIamInstanceProfileAssociations" // DescribeIamInstanceProfileAssociationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeIamInstanceProfileAssociations operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13808,12 +10051,6 @@ func (c *EC2) DescribeIamInstanceProfileAssociationsRequest(input *DescribeIamIn Name: opDescribeIamInstanceProfileAssociations, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -13857,62 +10094,12 @@ func (c *EC2) DescribeIamInstanceProfileAssociationsWithContext(ctx aws.Context, return out, req.Send() } -// DescribeIamInstanceProfileAssociationsPages iterates over the pages of a DescribeIamInstanceProfileAssociations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeIamInstanceProfileAssociations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeIamInstanceProfileAssociations operation. -// pageNum := 0 -// err := client.DescribeIamInstanceProfileAssociationsPages(params, -// func(page *ec2.DescribeIamInstanceProfileAssociationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeIamInstanceProfileAssociationsPages(input *DescribeIamInstanceProfileAssociationsInput, fn func(*DescribeIamInstanceProfileAssociationsOutput, bool) bool) error { - return c.DescribeIamInstanceProfileAssociationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeIamInstanceProfileAssociationsPagesWithContext same as DescribeIamInstanceProfileAssociationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeIamInstanceProfileAssociationsPagesWithContext(ctx aws.Context, input *DescribeIamInstanceProfileAssociationsInput, fn func(*DescribeIamInstanceProfileAssociationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeIamInstanceProfileAssociationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeIamInstanceProfileAssociationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeIamInstanceProfileAssociationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeIdFormat = "DescribeIdFormat" // DescribeIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -13951,7 +10138,7 @@ func (c *EC2) DescribeIdFormatRequest(input *DescribeIdFormatInput) (req *reques // DescribeIdFormat API operation for Amazon Elastic Compute Cloud. // -// Describes the ID format settings for your resources on a per-Region basis, +// Describes the ID format settings for your resources on a per-region basis, // for example, to view which resource types are enabled for longer IDs. This // request only returns information about resource types whose ID formats can // be modified; it does not return information about other resource types. @@ -14004,7 +10191,7 @@ const opDescribeIdentityIdFormat = "DescribeIdentityIdFormat" // DescribeIdentityIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribeIdentityIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14047,7 +10234,7 @@ func (c *EC2) DescribeIdentityIdFormatRequest(input *DescribeIdentityIdFormatInp // IAM role, or root user. For example, you can view the resource types that // are enabled for longer IDs. This request only returns information about resource // types whose ID formats can be modified; it does not return information about -// other resource types. For more information, see Resource IDs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) +// other resource types. For more information, see Resource IDs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) // in the Amazon Elastic Compute Cloud User Guide. // // The following resource types support longer IDs: bundle | conversion-task @@ -14094,7 +10281,7 @@ const opDescribeImageAttribute = "DescribeImageAttribute" // DescribeImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14169,7 +10356,7 @@ const opDescribeImages = "DescribeImages" // DescribeImagesRequest generates a "aws/request.Request" representing the // client's request for the DescribeImages operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14208,17 +10395,13 @@ func (c *EC2) DescribeImagesRequest(input *DescribeImagesInput) (req *request.Re // DescribeImages API operation for Amazon Elastic Compute Cloud. // -// Describes the specified images (AMIs, AKIs, and ARIs) available to you or -// all of the images available to you. -// -// The images available to you include public images, private images that you -// own, and private images owned by other AWS accounts for which you have explicit +// Describes one or more of the images (AMIs, AKIs, and ARIs) available to you. +// Images available to you include public images, private images that you own, +// and private images owned by other AWS accounts but for which you have explicit // launch permissions. // -// Recently deregistered images appear in the returned results for a short interval -// and then return empty results. After all instances that reference a deregistered -// AMI are terminated, specifying the ID of the image results in an error indicating -// that the AMI ID cannot be found. +// Deregistered images are included in the returned results for an unspecified +// interval after deregistration. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -14253,7 +10436,7 @@ const opDescribeImportImageTasks = "DescribeImportImageTasks" // DescribeImportImageTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeImportImageTasks operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14279,12 +10462,6 @@ func (c *EC2) DescribeImportImageTasksRequest(input *DescribeImportImageTasksInp Name: opDescribeImportImageTasks, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -14329,62 +10506,12 @@ func (c *EC2) DescribeImportImageTasksWithContext(ctx aws.Context, input *Descri return out, req.Send() } -// DescribeImportImageTasksPages iterates over the pages of a DescribeImportImageTasks operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeImportImageTasks method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeImportImageTasks operation. -// pageNum := 0 -// err := client.DescribeImportImageTasksPages(params, -// func(page *ec2.DescribeImportImageTasksOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeImportImageTasksPages(input *DescribeImportImageTasksInput, fn func(*DescribeImportImageTasksOutput, bool) bool) error { - return c.DescribeImportImageTasksPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeImportImageTasksPagesWithContext same as DescribeImportImageTasksPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeImportImageTasksPagesWithContext(ctx aws.Context, input *DescribeImportImageTasksInput, fn func(*DescribeImportImageTasksOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeImportImageTasksInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeImportImageTasksRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeImportImageTasksOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeImportSnapshotTasks = "DescribeImportSnapshotTasks" // DescribeImportSnapshotTasksRequest generates a "aws/request.Request" representing the // client's request for the DescribeImportSnapshotTasks operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14410,12 +10537,6 @@ func (c *EC2) DescribeImportSnapshotTasksRequest(input *DescribeImportSnapshotTa Name: opDescribeImportSnapshotTasks, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -14459,62 +10580,12 @@ func (c *EC2) DescribeImportSnapshotTasksWithContext(ctx aws.Context, input *Des return out, req.Send() } -// DescribeImportSnapshotTasksPages iterates over the pages of a DescribeImportSnapshotTasks operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeImportSnapshotTasks method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeImportSnapshotTasks operation. -// pageNum := 0 -// err := client.DescribeImportSnapshotTasksPages(params, -// func(page *ec2.DescribeImportSnapshotTasksOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeImportSnapshotTasksPages(input *DescribeImportSnapshotTasksInput, fn func(*DescribeImportSnapshotTasksOutput, bool) bool) error { - return c.DescribeImportSnapshotTasksPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeImportSnapshotTasksPagesWithContext same as DescribeImportSnapshotTasksPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeImportSnapshotTasksPagesWithContext(ctx aws.Context, input *DescribeImportSnapshotTasksInput, fn func(*DescribeImportSnapshotTasksOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeImportSnapshotTasksInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeImportSnapshotTasksRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeImportSnapshotTasksOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeInstanceAttribute = "DescribeInstanceAttribute" // DescribeInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14592,7 +10663,7 @@ const opDescribeInstanceCreditSpecifications = "DescribeInstanceCreditSpecificat // DescribeInstanceCreditSpecificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceCreditSpecifications operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14618,12 +10689,6 @@ func (c *EC2) DescribeInstanceCreditSpecificationsRequest(input *DescribeInstanc Name: opDescribeInstanceCreditSpecifications, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -14637,19 +10702,14 @@ func (c *EC2) DescribeInstanceCreditSpecificationsRequest(input *DescribeInstanc // DescribeInstanceCreditSpecifications API operation for Amazon Elastic Compute Cloud. // -// Describes the credit option for CPU usage of the specified T2 or T3 instances. +// Describes the credit option for CPU usage of one or more of your T2 instances. // The credit options are standard and unlimited. // -// If you do not specify an instance ID, Amazon EC2 returns T2 and T3 instances -// with the unlimited credit option, as well as instances that were previously -// configured as T2 or T3 with the unlimited credit option. For example, if -// you resize a T2 instance, while it is configured as unlimited, to an M4 instance, -// Amazon EC2 returns the M4 instance. -// -// If you specify one or more instance IDs, Amazon EC2 returns the credit option -// (standard or unlimited) of those instances. If you specify an instance ID -// that is not valid, such as an instance that is not a T2 or T3 instance, an -// error is returned. +// If you do not specify an instance ID, Amazon EC2 returns only the T2 instances +// with the unlimited credit option. If you specify one or more instance IDs, +// Amazon EC2 returns the credit option (standard or unlimited) of those instances. +// If you specify an instance ID that is not valid, such as an instance that +// is not a T2 instance, an error is returned. // // Recently terminated instances might appear in the returned results. This // interval is usually less than one hour. @@ -14659,7 +10719,7 @@ func (c *EC2) DescribeInstanceCreditSpecificationsRequest(input *DescribeInstanc // all, the call fails. If you specify only instance IDs in an unaffected zone, // the call works normally. // -// For more information, see Burstable Performance Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/burstable-performance-instances.html) +// For more information, see T2 Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -14690,62 +10750,12 @@ func (c *EC2) DescribeInstanceCreditSpecificationsWithContext(ctx aws.Context, i return out, req.Send() } -// DescribeInstanceCreditSpecificationsPages iterates over the pages of a DescribeInstanceCreditSpecifications operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeInstanceCreditSpecifications method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeInstanceCreditSpecifications operation. -// pageNum := 0 -// err := client.DescribeInstanceCreditSpecificationsPages(params, -// func(page *ec2.DescribeInstanceCreditSpecificationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeInstanceCreditSpecificationsPages(input *DescribeInstanceCreditSpecificationsInput, fn func(*DescribeInstanceCreditSpecificationsOutput, bool) bool) error { - return c.DescribeInstanceCreditSpecificationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeInstanceCreditSpecificationsPagesWithContext same as DescribeInstanceCreditSpecificationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeInstanceCreditSpecificationsPagesWithContext(ctx aws.Context, input *DescribeInstanceCreditSpecificationsInput, fn func(*DescribeInstanceCreditSpecificationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeInstanceCreditSpecificationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeInstanceCreditSpecificationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeInstanceCreditSpecificationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeInstanceStatus = "DescribeInstanceStatus" // DescribeInstanceStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstanceStatus operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14790,27 +10800,27 @@ func (c *EC2) DescribeInstanceStatusRequest(input *DescribeInstanceStatusInput) // DescribeInstanceStatus API operation for Amazon Elastic Compute Cloud. // -// Describes the status of the specified instances or all of your instances. -// By default, only running instances are described, unless you specifically -// indicate to return the status of all instances. +// Describes the status of one or more instances. By default, only running instances +// are described, unless you specifically indicate to return the status of all +// instances. // // Instance status includes the following components: // // * Status checks - Amazon EC2 performs status checks on running EC2 instances // to identify hardware and software issues. For more information, see Status -// Checks for Your Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-system-instance-status-check.html) -// and Troubleshooting Instances with Failed Status Checks (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstances.html) +// Checks for Your Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-system-instance-status-check.html) +// and Troubleshooting Instances with Failed Status Checks (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstances.html) // in the Amazon Elastic Compute Cloud User Guide. // // * Scheduled events - Amazon EC2 can schedule events (such as reboot, stop, // or terminate) for your instances related to hardware issues, software // updates, or system maintenance. For more information, see Scheduled Events -// for Your Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-instances-status-check_sched.html) +// for Your Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-instances-status-check_sched.html) // in the Amazon Elastic Compute Cloud User Guide. // // * Instance state - You can manage your instances from the moment you launch // them through their termination. For more information, see Instance Lifecycle -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -14852,7 +10862,7 @@ func (c *EC2) DescribeInstanceStatusWithContext(ctx aws.Context, input *Describe // // Example iterating over at most 3 pages of a DescribeInstanceStatus operation. // pageNum := 0 // err := client.DescribeInstanceStatusPages(params, -// func(page *ec2.DescribeInstanceStatusOutput, lastPage bool) bool { +// func(page *DescribeInstanceStatusOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -14896,7 +10906,7 @@ const opDescribeInstances = "DescribeInstances" // DescribeInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -14941,7 +10951,7 @@ func (c *EC2) DescribeInstancesRequest(input *DescribeInstancesInput) (req *requ // DescribeInstances API operation for Amazon Elastic Compute Cloud. // -// Describes the specified instances or all of AWS account's instances. +// Describes one or more of your instances. // // If you specify one or more instance IDs, Amazon EC2 returns information for // those instances. If you do not specify instance IDs, Amazon EC2 returns information @@ -14997,7 +11007,7 @@ func (c *EC2) DescribeInstancesWithContext(ctx aws.Context, input *DescribeInsta // // Example iterating over at most 3 pages of a DescribeInstances operation. // pageNum := 0 // err := client.DescribeInstancesPages(params, -// func(page *ec2.DescribeInstancesOutput, lastPage bool) bool { +// func(page *DescribeInstancesOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -15041,7 +11051,7 @@ const opDescribeInternetGateways = "DescribeInternetGateways" // DescribeInternetGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeInternetGateways operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15067,12 +11077,6 @@ func (c *EC2) DescribeInternetGatewaysRequest(input *DescribeInternetGatewaysInp Name: opDescribeInternetGateways, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -15116,62 +11120,12 @@ func (c *EC2) DescribeInternetGatewaysWithContext(ctx aws.Context, input *Descri return out, req.Send() } -// DescribeInternetGatewaysPages iterates over the pages of a DescribeInternetGateways operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeInternetGateways method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeInternetGateways operation. -// pageNum := 0 -// err := client.DescribeInternetGatewaysPages(params, -// func(page *ec2.DescribeInternetGatewaysOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeInternetGatewaysPages(input *DescribeInternetGatewaysInput, fn func(*DescribeInternetGatewaysOutput, bool) bool) error { - return c.DescribeInternetGatewaysPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeInternetGatewaysPagesWithContext same as DescribeInternetGatewaysPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeInternetGatewaysPagesWithContext(ctx aws.Context, input *DescribeInternetGatewaysInput, fn func(*DescribeInternetGatewaysOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeInternetGatewaysInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeInternetGatewaysRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeInternetGatewaysOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeKeyPairs = "DescribeKeyPairs" // DescribeKeyPairsRequest generates a "aws/request.Request" representing the // client's request for the DescribeKeyPairs operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15210,9 +11164,9 @@ func (c *EC2) DescribeKeyPairsRequest(input *DescribeKeyPairsInput) (req *reques // DescribeKeyPairs API operation for Amazon Elastic Compute Cloud. // -// Describes the specified key pairs or all of your key pairs. +// Describes one or more of your key pairs. // -// For more information about key pairs, see Key Pairs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) +// For more information about key pairs, see Key Pairs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -15248,7 +11202,7 @@ const opDescribeLaunchTemplateVersions = "DescribeLaunchTemplateVersions" // DescribeLaunchTemplateVersionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeLaunchTemplateVersions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15274,12 +11228,6 @@ func (c *EC2) DescribeLaunchTemplateVersionsRequest(input *DescribeLaunchTemplat Name: opDescribeLaunchTemplateVersions, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -15324,62 +11272,12 @@ func (c *EC2) DescribeLaunchTemplateVersionsWithContext(ctx aws.Context, input * return out, req.Send() } -// DescribeLaunchTemplateVersionsPages iterates over the pages of a DescribeLaunchTemplateVersions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeLaunchTemplateVersions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeLaunchTemplateVersions operation. -// pageNum := 0 -// err := client.DescribeLaunchTemplateVersionsPages(params, -// func(page *ec2.DescribeLaunchTemplateVersionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeLaunchTemplateVersionsPages(input *DescribeLaunchTemplateVersionsInput, fn func(*DescribeLaunchTemplateVersionsOutput, bool) bool) error { - return c.DescribeLaunchTemplateVersionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeLaunchTemplateVersionsPagesWithContext same as DescribeLaunchTemplateVersionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeLaunchTemplateVersionsPagesWithContext(ctx aws.Context, input *DescribeLaunchTemplateVersionsInput, fn func(*DescribeLaunchTemplateVersionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeLaunchTemplateVersionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeLaunchTemplateVersionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeLaunchTemplateVersionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeLaunchTemplates = "DescribeLaunchTemplates" // DescribeLaunchTemplatesRequest generates a "aws/request.Request" representing the // client's request for the DescribeLaunchTemplates operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15405,12 +11303,6 @@ func (c *EC2) DescribeLaunchTemplatesRequest(input *DescribeLaunchTemplatesInput Name: opDescribeLaunchTemplates, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -15454,62 +11346,12 @@ func (c *EC2) DescribeLaunchTemplatesWithContext(ctx aws.Context, input *Describ return out, req.Send() } -// DescribeLaunchTemplatesPages iterates over the pages of a DescribeLaunchTemplates operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeLaunchTemplates method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeLaunchTemplates operation. -// pageNum := 0 -// err := client.DescribeLaunchTemplatesPages(params, -// func(page *ec2.DescribeLaunchTemplatesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeLaunchTemplatesPages(input *DescribeLaunchTemplatesInput, fn func(*DescribeLaunchTemplatesOutput, bool) bool) error { - return c.DescribeLaunchTemplatesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeLaunchTemplatesPagesWithContext same as DescribeLaunchTemplatesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeLaunchTemplatesPagesWithContext(ctx aws.Context, input *DescribeLaunchTemplatesInput, fn func(*DescribeLaunchTemplatesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeLaunchTemplatesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeLaunchTemplatesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeLaunchTemplatesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeMovingAddresses = "DescribeMovingAddresses" // DescribeMovingAddressesRequest generates a "aws/request.Request" representing the // client's request for the DescribeMovingAddresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15535,12 +11377,6 @@ func (c *EC2) DescribeMovingAddressesRequest(input *DescribeMovingAddressesInput Name: opDescribeMovingAddresses, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -15586,62 +11422,12 @@ func (c *EC2) DescribeMovingAddressesWithContext(ctx aws.Context, input *Describ return out, req.Send() } -// DescribeMovingAddressesPages iterates over the pages of a DescribeMovingAddresses operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeMovingAddresses method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeMovingAddresses operation. -// pageNum := 0 -// err := client.DescribeMovingAddressesPages(params, -// func(page *ec2.DescribeMovingAddressesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeMovingAddressesPages(input *DescribeMovingAddressesInput, fn func(*DescribeMovingAddressesOutput, bool) bool) error { - return c.DescribeMovingAddressesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeMovingAddressesPagesWithContext same as DescribeMovingAddressesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeMovingAddressesPagesWithContext(ctx aws.Context, input *DescribeMovingAddressesInput, fn func(*DescribeMovingAddressesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeMovingAddressesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeMovingAddressesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeMovingAddressesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeNatGateways = "DescribeNatGateways" // DescribeNatGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeNatGateways operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15727,7 +11513,7 @@ func (c *EC2) DescribeNatGatewaysWithContext(ctx aws.Context, input *DescribeNat // // Example iterating over at most 3 pages of a DescribeNatGateways operation. // pageNum := 0 // err := client.DescribeNatGatewaysPages(params, -// func(page *ec2.DescribeNatGatewaysOutput, lastPage bool) bool { +// func(page *DescribeNatGatewaysOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -15771,7 +11557,7 @@ const opDescribeNetworkAcls = "DescribeNetworkAcls" // DescribeNetworkAclsRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkAcls operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15797,12 +11583,6 @@ func (c *EC2) DescribeNetworkAclsRequest(input *DescribeNetworkAclsInput) (req * Name: opDescribeNetworkAcls, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -15818,7 +11598,7 @@ func (c *EC2) DescribeNetworkAclsRequest(input *DescribeNetworkAclsInput) (req * // // Describes one or more of your network ACLs. // -// For more information, see Network ACLs (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_ACLs.html) +// For more information, see Network ACLs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -15849,62 +11629,12 @@ func (c *EC2) DescribeNetworkAclsWithContext(ctx aws.Context, input *DescribeNet return out, req.Send() } -// DescribeNetworkAclsPages iterates over the pages of a DescribeNetworkAcls operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeNetworkAcls method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeNetworkAcls operation. -// pageNum := 0 -// err := client.DescribeNetworkAclsPages(params, -// func(page *ec2.DescribeNetworkAclsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeNetworkAclsPages(input *DescribeNetworkAclsInput, fn func(*DescribeNetworkAclsOutput, bool) bool) error { - return c.DescribeNetworkAclsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeNetworkAclsPagesWithContext same as DescribeNetworkAclsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeNetworkAclsPagesWithContext(ctx aws.Context, input *DescribeNetworkAclsInput, fn func(*DescribeNetworkAclsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeNetworkAclsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeNetworkAclsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeNetworkAclsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeNetworkInterfaceAttribute = "DescribeNetworkInterfaceAttribute" // DescribeNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfaceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -15979,7 +11709,7 @@ const opDescribeNetworkInterfacePermissions = "DescribeNetworkInterfacePermissio // DescribeNetworkInterfacePermissionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfacePermissions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16005,12 +11735,6 @@ func (c *EC2) DescribeNetworkInterfacePermissionsRequest(input *DescribeNetworkI Name: opDescribeNetworkInterfacePermissions, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -16054,62 +11778,12 @@ func (c *EC2) DescribeNetworkInterfacePermissionsWithContext(ctx aws.Context, in return out, req.Send() } -// DescribeNetworkInterfacePermissionsPages iterates over the pages of a DescribeNetworkInterfacePermissions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeNetworkInterfacePermissions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeNetworkInterfacePermissions operation. -// pageNum := 0 -// err := client.DescribeNetworkInterfacePermissionsPages(params, -// func(page *ec2.DescribeNetworkInterfacePermissionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeNetworkInterfacePermissionsPages(input *DescribeNetworkInterfacePermissionsInput, fn func(*DescribeNetworkInterfacePermissionsOutput, bool) bool) error { - return c.DescribeNetworkInterfacePermissionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeNetworkInterfacePermissionsPagesWithContext same as DescribeNetworkInterfacePermissionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeNetworkInterfacePermissionsPagesWithContext(ctx aws.Context, input *DescribeNetworkInterfacePermissionsInput, fn func(*DescribeNetworkInterfacePermissionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeNetworkInterfacePermissionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeNetworkInterfacePermissionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeNetworkInterfacePermissionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeNetworkInterfaces = "DescribeNetworkInterfaces" // DescribeNetworkInterfacesRequest generates a "aws/request.Request" representing the // client's request for the DescribeNetworkInterfaces operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16135,12 +11809,6 @@ func (c *EC2) DescribeNetworkInterfacesRequest(input *DescribeNetworkInterfacesI Name: opDescribeNetworkInterfaces, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -16184,62 +11852,12 @@ func (c *EC2) DescribeNetworkInterfacesWithContext(ctx aws.Context, input *Descr return out, req.Send() } -// DescribeNetworkInterfacesPages iterates over the pages of a DescribeNetworkInterfaces operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeNetworkInterfaces method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeNetworkInterfaces operation. -// pageNum := 0 -// err := client.DescribeNetworkInterfacesPages(params, -// func(page *ec2.DescribeNetworkInterfacesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeNetworkInterfacesPages(input *DescribeNetworkInterfacesInput, fn func(*DescribeNetworkInterfacesOutput, bool) bool) error { - return c.DescribeNetworkInterfacesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeNetworkInterfacesPagesWithContext same as DescribeNetworkInterfacesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeNetworkInterfacesPagesWithContext(ctx aws.Context, input *DescribeNetworkInterfacesInput, fn func(*DescribeNetworkInterfacesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeNetworkInterfacesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeNetworkInterfacesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeNetworkInterfacesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribePlacementGroups = "DescribePlacementGroups" // DescribePlacementGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribePlacementGroups operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16278,8 +11896,8 @@ func (c *EC2) DescribePlacementGroupsRequest(input *DescribePlacementGroupsInput // DescribePlacementGroups API operation for Amazon Elastic Compute Cloud. // -// Describes the specified placement groups or all of your placement groups. -// For more information, see Placement Groups (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) +// Describes one or more of your placement groups. For more information, see +// Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -16315,7 +11933,7 @@ const opDescribePrefixLists = "DescribePrefixLists" // DescribePrefixListsRequest generates a "aws/request.Request" representing the // client's request for the DescribePrefixLists operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16341,12 +11959,6 @@ func (c *EC2) DescribePrefixListsRequest(input *DescribePrefixListsInput) (req * Name: opDescribePrefixLists, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -16395,62 +12007,12 @@ func (c *EC2) DescribePrefixListsWithContext(ctx aws.Context, input *DescribePre return out, req.Send() } -// DescribePrefixListsPages iterates over the pages of a DescribePrefixLists operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribePrefixLists method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribePrefixLists operation. -// pageNum := 0 -// err := client.DescribePrefixListsPages(params, -// func(page *ec2.DescribePrefixListsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribePrefixListsPages(input *DescribePrefixListsInput, fn func(*DescribePrefixListsOutput, bool) bool) error { - return c.DescribePrefixListsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribePrefixListsPagesWithContext same as DescribePrefixListsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribePrefixListsPagesWithContext(ctx aws.Context, input *DescribePrefixListsInput, fn func(*DescribePrefixListsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribePrefixListsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribePrefixListsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribePrefixListsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribePrincipalIdFormat = "DescribePrincipalIdFormat" // DescribePrincipalIdFormatRequest generates a "aws/request.Request" representing the // client's request for the DescribePrincipalIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16476,12 +12038,6 @@ func (c *EC2) DescribePrincipalIdFormatRequest(input *DescribePrincipalIdFormatI Name: opDescribePrincipalIdFormat, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -16539,192 +12095,12 @@ func (c *EC2) DescribePrincipalIdFormatWithContext(ctx aws.Context, input *Descr return out, req.Send() } -// DescribePrincipalIdFormatPages iterates over the pages of a DescribePrincipalIdFormat operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribePrincipalIdFormat method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribePrincipalIdFormat operation. -// pageNum := 0 -// err := client.DescribePrincipalIdFormatPages(params, -// func(page *ec2.DescribePrincipalIdFormatOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribePrincipalIdFormatPages(input *DescribePrincipalIdFormatInput, fn func(*DescribePrincipalIdFormatOutput, bool) bool) error { - return c.DescribePrincipalIdFormatPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribePrincipalIdFormatPagesWithContext same as DescribePrincipalIdFormatPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribePrincipalIdFormatPagesWithContext(ctx aws.Context, input *DescribePrincipalIdFormatInput, fn func(*DescribePrincipalIdFormatOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribePrincipalIdFormatInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribePrincipalIdFormatRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribePrincipalIdFormatOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribePublicIpv4Pools = "DescribePublicIpv4Pools" - -// DescribePublicIpv4PoolsRequest generates a "aws/request.Request" representing the -// client's request for the DescribePublicIpv4Pools operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribePublicIpv4Pools for more information on using the DescribePublicIpv4Pools -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribePublicIpv4PoolsRequest method. -// req, resp := client.DescribePublicIpv4PoolsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribePublicIpv4Pools -func (c *EC2) DescribePublicIpv4PoolsRequest(input *DescribePublicIpv4PoolsInput) (req *request.Request, output *DescribePublicIpv4PoolsOutput) { - op := &request.Operation{ - Name: opDescribePublicIpv4Pools, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribePublicIpv4PoolsInput{} - } - - output = &DescribePublicIpv4PoolsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribePublicIpv4Pools API operation for Amazon Elastic Compute Cloud. -// -// Describes the specified IPv4 address pools. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribePublicIpv4Pools for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribePublicIpv4Pools -func (c *EC2) DescribePublicIpv4Pools(input *DescribePublicIpv4PoolsInput) (*DescribePublicIpv4PoolsOutput, error) { - req, out := c.DescribePublicIpv4PoolsRequest(input) - return out, req.Send() -} - -// DescribePublicIpv4PoolsWithContext is the same as DescribePublicIpv4Pools with the addition of -// the ability to pass a context and additional request options. -// -// See DescribePublicIpv4Pools for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribePublicIpv4PoolsWithContext(ctx aws.Context, input *DescribePublicIpv4PoolsInput, opts ...request.Option) (*DescribePublicIpv4PoolsOutput, error) { - req, out := c.DescribePublicIpv4PoolsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribePublicIpv4PoolsPages iterates over the pages of a DescribePublicIpv4Pools operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribePublicIpv4Pools method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribePublicIpv4Pools operation. -// pageNum := 0 -// err := client.DescribePublicIpv4PoolsPages(params, -// func(page *ec2.DescribePublicIpv4PoolsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribePublicIpv4PoolsPages(input *DescribePublicIpv4PoolsInput, fn func(*DescribePublicIpv4PoolsOutput, bool) bool) error { - return c.DescribePublicIpv4PoolsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribePublicIpv4PoolsPagesWithContext same as DescribePublicIpv4PoolsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribePublicIpv4PoolsPagesWithContext(ctx aws.Context, input *DescribePublicIpv4PoolsInput, fn func(*DescribePublicIpv4PoolsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribePublicIpv4PoolsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribePublicIpv4PoolsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribePublicIpv4PoolsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeRegions = "DescribeRegions" // DescribeRegionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeRegions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16763,14 +12139,10 @@ func (c *EC2) DescribeRegionsRequest(input *DescribeRegionsInput) (req *request. // DescribeRegions API operation for Amazon Elastic Compute Cloud. // -// Describes the Regions that are currently available to you. The API returns -// a list of all the Regions, including Regions that are disabled for your account. -// For information about enabling Regions for your account, see Enabling and -// Disabling Regions (https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/manage-account-payment.html#manage-account-payment-enable-disable-regions) -// in the AWS Billing and Cost Management User Guide. +// Describes one or more regions that are currently available to you. // -// For a list of the Regions supported by Amazon EC2, see Regions and Endpoints -// (https://docs.aws.amazon.com/general/latest/gr/rande.html#ec2_region). +// For a list of the regions supported by Amazon EC2, see Regions and Endpoints +// (http://docs.aws.amazon.com/general/latest/gr/rande.html#ec2_region). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -16805,7 +12177,7 @@ const opDescribeReservedInstances = "DescribeReservedInstances" // DescribeReservedInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16846,7 +12218,7 @@ func (c *EC2) DescribeReservedInstancesRequest(input *DescribeReservedInstancesI // // Describes one or more of the Reserved Instances that you purchased. // -// For more information about Reserved Instances, see Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts-on-demand-reserved-instances.html) +// For more information about Reserved Instances, see Reserved Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts-on-demand-reserved-instances.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -16882,7 +12254,7 @@ const opDescribeReservedInstancesListings = "DescribeReservedInstancesListings" // DescribeReservedInstancesListingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesListings operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -16941,7 +12313,7 @@ func (c *EC2) DescribeReservedInstancesListingsRequest(input *DescribeReservedIn // demand is met. You are charged based on the total price of all of the listings // that you purchase. // -// For more information, see Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) +// For more information, see Reserved Instance Marketplace (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -16977,7 +12349,7 @@ const opDescribeReservedInstancesModifications = "DescribeReservedInstancesModif // DescribeReservedInstancesModificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesModifications operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17027,7 +12399,7 @@ func (c *EC2) DescribeReservedInstancesModificationsRequest(input *DescribeReser // requests is returned. If a modification ID is specified, only information // about the specific modification is returned. // -// For more information, see Modifying Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html) +// For more information, see Modifying Reserved Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17069,7 +12441,7 @@ func (c *EC2) DescribeReservedInstancesModificationsWithContext(ctx aws.Context, // // Example iterating over at most 3 pages of a DescribeReservedInstancesModifications operation. // pageNum := 0 // err := client.DescribeReservedInstancesModificationsPages(params, -// func(page *ec2.DescribeReservedInstancesModificationsOutput, lastPage bool) bool { +// func(page *DescribeReservedInstancesModificationsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -17113,7 +12485,7 @@ const opDescribeReservedInstancesOfferings = "DescribeReservedInstancesOfferings // DescribeReservedInstancesOfferingsRequest generates a "aws/request.Request" representing the // client's request for the DescribeReservedInstancesOfferings operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17168,7 +12540,7 @@ func (c *EC2) DescribeReservedInstancesOfferingsRequest(input *DescribeReservedI // Marketplace, they will be excluded from these results. This is to ensure // that you do not purchase your own Reserved Instances. // -// For more information, see Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) +// For more information, see Reserved Instance Marketplace (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17210,7 +12582,7 @@ func (c *EC2) DescribeReservedInstancesOfferingsWithContext(ctx aws.Context, inp // // Example iterating over at most 3 pages of a DescribeReservedInstancesOfferings operation. // pageNum := 0 // err := client.DescribeReservedInstancesOfferingsPages(params, -// func(page *ec2.DescribeReservedInstancesOfferingsOutput, lastPage bool) bool { +// func(page *DescribeReservedInstancesOfferingsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -17254,7 +12626,7 @@ const opDescribeRouteTables = "DescribeRouteTables" // DescribeRouteTablesRequest generates a "aws/request.Request" representing the // client's request for the DescribeRouteTables operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17280,12 +12652,6 @@ func (c *EC2) DescribeRouteTablesRequest(input *DescribeRouteTablesInput) (req * Name: opDescribeRouteTables, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -17306,7 +12672,7 @@ func (c *EC2) DescribeRouteTablesRequest(input *DescribeRouteTablesInput) (req * // with the main route table. This command does not return the subnet ID for // implicit associations. // -// For more information, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// For more information, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17337,62 +12703,12 @@ func (c *EC2) DescribeRouteTablesWithContext(ctx aws.Context, input *DescribeRou return out, req.Send() } -// DescribeRouteTablesPages iterates over the pages of a DescribeRouteTables operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeRouteTables method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeRouteTables operation. -// pageNum := 0 -// err := client.DescribeRouteTablesPages(params, -// func(page *ec2.DescribeRouteTablesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeRouteTablesPages(input *DescribeRouteTablesInput, fn func(*DescribeRouteTablesOutput, bool) bool) error { - return c.DescribeRouteTablesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeRouteTablesPagesWithContext same as DescribeRouteTablesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeRouteTablesPagesWithContext(ctx aws.Context, input *DescribeRouteTablesInput, fn func(*DescribeRouteTablesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeRouteTablesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeRouteTablesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeRouteTablesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeScheduledInstanceAvailability = "DescribeScheduledInstanceAvailability" // DescribeScheduledInstanceAvailabilityRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledInstanceAvailability operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17418,12 +12734,6 @@ func (c *EC2) DescribeScheduledInstanceAvailabilityRequest(input *DescribeSchedu Name: opDescribeScheduledInstanceAvailability, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -17475,62 +12785,12 @@ func (c *EC2) DescribeScheduledInstanceAvailabilityWithContext(ctx aws.Context, return out, req.Send() } -// DescribeScheduledInstanceAvailabilityPages iterates over the pages of a DescribeScheduledInstanceAvailability operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeScheduledInstanceAvailability method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeScheduledInstanceAvailability operation. -// pageNum := 0 -// err := client.DescribeScheduledInstanceAvailabilityPages(params, -// func(page *ec2.DescribeScheduledInstanceAvailabilityOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeScheduledInstanceAvailabilityPages(input *DescribeScheduledInstanceAvailabilityInput, fn func(*DescribeScheduledInstanceAvailabilityOutput, bool) bool) error { - return c.DescribeScheduledInstanceAvailabilityPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeScheduledInstanceAvailabilityPagesWithContext same as DescribeScheduledInstanceAvailabilityPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeScheduledInstanceAvailabilityPagesWithContext(ctx aws.Context, input *DescribeScheduledInstanceAvailabilityInput, fn func(*DescribeScheduledInstanceAvailabilityOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeScheduledInstanceAvailabilityInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeScheduledInstanceAvailabilityRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeScheduledInstanceAvailabilityOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeScheduledInstances = "DescribeScheduledInstances" // DescribeScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeScheduledInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17556,12 +12816,6 @@ func (c *EC2) DescribeScheduledInstancesRequest(input *DescribeScheduledInstance Name: opDescribeScheduledInstances, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -17575,7 +12829,7 @@ func (c *EC2) DescribeScheduledInstancesRequest(input *DescribeScheduledInstance // DescribeScheduledInstances API operation for Amazon Elastic Compute Cloud. // -// Describes the specified Scheduled Instances or all your Scheduled Instances. +// Describes one or more of your Scheduled Instances. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -17605,62 +12859,12 @@ func (c *EC2) DescribeScheduledInstancesWithContext(ctx aws.Context, input *Desc return out, req.Send() } -// DescribeScheduledInstancesPages iterates over the pages of a DescribeScheduledInstances operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeScheduledInstances method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeScheduledInstances operation. -// pageNum := 0 -// err := client.DescribeScheduledInstancesPages(params, -// func(page *ec2.DescribeScheduledInstancesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeScheduledInstancesPages(input *DescribeScheduledInstancesInput, fn func(*DescribeScheduledInstancesOutput, bool) bool) error { - return c.DescribeScheduledInstancesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeScheduledInstancesPagesWithContext same as DescribeScheduledInstancesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeScheduledInstancesPagesWithContext(ctx aws.Context, input *DescribeScheduledInstancesInput, fn func(*DescribeScheduledInstancesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeScheduledInstancesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeScheduledInstancesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeScheduledInstancesOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeSecurityGroupReferences = "DescribeSecurityGroupReferences" // DescribeSecurityGroupReferencesRequest generates a "aws/request.Request" representing the // client's request for the DescribeSecurityGroupReferences operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17699,7 +12903,7 @@ func (c *EC2) DescribeSecurityGroupReferencesRequest(input *DescribeSecurityGrou // DescribeSecurityGroupReferences API operation for Amazon Elastic Compute Cloud. // -// [VPC only] Describes the VPCs on the other side of a VPC peering connection +// [EC2-VPC only] Describes the VPCs on the other side of a VPC peering connection // that are referencing the security groups you've specified in this request. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17735,7 +12939,7 @@ const opDescribeSecurityGroups = "DescribeSecurityGroups" // DescribeSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSecurityGroups operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17761,12 +12965,6 @@ func (c *EC2) DescribeSecurityGroupsRequest(input *DescribeSecurityGroupsInput) Name: opDescribeSecurityGroups, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -17780,13 +12978,13 @@ func (c *EC2) DescribeSecurityGroupsRequest(input *DescribeSecurityGroupsInput) // DescribeSecurityGroups API operation for Amazon Elastic Compute Cloud. // -// Describes the specified security groups or all of your security groups. +// Describes one or more of your security groups. // // A security group is for use with instances either in the EC2-Classic platform // or in a specific VPC. For more information, see Amazon EC2 Security Groups -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html) // in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your -// VPC (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html) +// VPC (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_SecurityGroups.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17817,62 +13015,12 @@ func (c *EC2) DescribeSecurityGroupsWithContext(ctx aws.Context, input *Describe return out, req.Send() } -// DescribeSecurityGroupsPages iterates over the pages of a DescribeSecurityGroups operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeSecurityGroups method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeSecurityGroups operation. -// pageNum := 0 -// err := client.DescribeSecurityGroupsPages(params, -// func(page *ec2.DescribeSecurityGroupsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeSecurityGroupsPages(input *DescribeSecurityGroupsInput, fn func(*DescribeSecurityGroupsOutput, bool) bool) error { - return c.DescribeSecurityGroupsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeSecurityGroupsPagesWithContext same as DescribeSecurityGroupsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeSecurityGroupsPagesWithContext(ctx aws.Context, input *DescribeSecurityGroupsInput, fn func(*DescribeSecurityGroupsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeSecurityGroupsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeSecurityGroupsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeSecurityGroupsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeSnapshotAttribute = "DescribeSnapshotAttribute" // DescribeSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshotAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17914,7 +13062,7 @@ func (c *EC2) DescribeSnapshotAttributeRequest(input *DescribeSnapshotAttributeI // Describes the specified attribute of the specified snapshot. You can specify // only one attribute at a time. // -// For more information about EBS snapshots, see Amazon EBS Snapshots (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html) +// For more information about EBS snapshots, see Amazon EBS Snapshots (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -17950,7 +13098,7 @@ const opDescribeSnapshots = "DescribeSnapshots" // DescribeSnapshotsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSnapshots operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -17995,12 +13143,10 @@ func (c *EC2) DescribeSnapshotsRequest(input *DescribeSnapshotsInput) (req *requ // DescribeSnapshots API operation for Amazon Elastic Compute Cloud. // -// Describes the specified EBS snapshots available to you or all of the EBS -// snapshots available to you. -// -// The snapshots available to you include public snapshots, private snapshots -// that you own, and private snapshots owned by other AWS accounts for which -// you have explicit create volume permissions. +// Describes one or more of the EBS snapshots available to you. Available snapshots +// include public snapshots available for any AWS account to launch, private +// snapshots that you own, and private snapshots owned by another AWS account +// but for which you've been given explicit create volume permissions. // // The create volume permissions fall into the following categories: // @@ -18041,7 +13187,7 @@ func (c *EC2) DescribeSnapshotsRequest(input *DescribeSnapshotsInput) (req *requ // a NextToken value that can be passed to a subsequent DescribeSnapshots request // to retrieve the remaining results. // -// For more information about EBS snapshots, see Amazon EBS Snapshots (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html) +// For more information about EBS snapshots, see Amazon EBS Snapshots (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSSnapshots.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -18083,7 +13229,7 @@ func (c *EC2) DescribeSnapshotsWithContext(ctx aws.Context, input *DescribeSnaps // // Example iterating over at most 3 pages of a DescribeSnapshots operation. // pageNum := 0 // err := client.DescribeSnapshotsPages(params, -// func(page *ec2.DescribeSnapshotsOutput, lastPage bool) bool { +// func(page *DescribeSnapshotsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -18127,7 +13273,7 @@ const opDescribeSpotDatafeedSubscription = "DescribeSpotDatafeedSubscription" // DescribeSpotDatafeedSubscriptionRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotDatafeedSubscription operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18167,7 +13313,7 @@ func (c *EC2) DescribeSpotDatafeedSubscriptionRequest(input *DescribeSpotDatafee // DescribeSpotDatafeedSubscription API operation for Amazon Elastic Compute Cloud. // // Describes the data feed for Spot Instances. For more information, see Spot -// Instance Data Feed (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-data-feeds.html) +// Instance Data Feed (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-data-feeds.html) // in the Amazon EC2 User Guide for Linux Instances. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -18203,7 +13349,7 @@ const opDescribeSpotFleetInstances = "DescribeSpotFleetInstances" // DescribeSpotFleetInstancesRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18277,7 +13423,7 @@ const opDescribeSpotFleetRequestHistory = "DescribeSpotFleetRequestHistory" // DescribeSpotFleetRequestHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetRequestHistory operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18321,7 +13467,7 @@ func (c *EC2) DescribeSpotFleetRequestHistoryRequest(input *DescribeSpotFleetReq // // Spot Fleet events are delayed by up to 30 seconds before they can be described. // This ensures that you can query by the last evaluated time and not miss a -// recorded event. Spot Fleet events are available for 48 hours. +// recorded event. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -18356,7 +13502,7 @@ const opDescribeSpotFleetRequests = "DescribeSpotFleetRequests" // DescribeSpotFleetRequestsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotFleetRequests operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18445,7 +13591,7 @@ func (c *EC2) DescribeSpotFleetRequestsWithContext(ctx aws.Context, input *Descr // // Example iterating over at most 3 pages of a DescribeSpotFleetRequests operation. // pageNum := 0 // err := client.DescribeSpotFleetRequestsPages(params, -// func(page *ec2.DescribeSpotFleetRequestsOutput, lastPage bool) bool { +// func(page *DescribeSpotFleetRequestsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -18489,7 +13635,7 @@ const opDescribeSpotInstanceRequests = "DescribeSpotInstanceRequests" // DescribeSpotInstanceRequestsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotInstanceRequests operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18515,12 +13661,6 @@ func (c *EC2) DescribeSpotInstanceRequestsRequest(input *DescribeSpotInstanceReq Name: opDescribeSpotInstanceRequests, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -18542,13 +13682,6 @@ func (c *EC2) DescribeSpotInstanceRequestsRequest(input *DescribeSpotInstanceReq // instance. Alternatively, you can use DescribeInstances with a filter to look // for instances where the instance lifecycle is spot. // -// We recommend that you set MaxResults to a value between 5 and 1000 to limit -// the number of results returned. This paginates the output, which makes the -// list more manageable and returns the results faster. If the list of results -// exceeds your MaxResults value, then that number of results is returned along -// with a NextToken value that can be passed to a subsequent DescribeSpotInstanceRequests -// request to retrieve the remaining results. -// // Spot Instance requests are deleted four hours after they are canceled and // their instances are terminated. // @@ -18580,62 +13713,12 @@ func (c *EC2) DescribeSpotInstanceRequestsWithContext(ctx aws.Context, input *De return out, req.Send() } -// DescribeSpotInstanceRequestsPages iterates over the pages of a DescribeSpotInstanceRequests operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeSpotInstanceRequests method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeSpotInstanceRequests operation. -// pageNum := 0 -// err := client.DescribeSpotInstanceRequestsPages(params, -// func(page *ec2.DescribeSpotInstanceRequestsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeSpotInstanceRequestsPages(input *DescribeSpotInstanceRequestsInput, fn func(*DescribeSpotInstanceRequestsOutput, bool) bool) error { - return c.DescribeSpotInstanceRequestsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeSpotInstanceRequestsPagesWithContext same as DescribeSpotInstanceRequestsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeSpotInstanceRequestsPagesWithContext(ctx aws.Context, input *DescribeSpotInstanceRequestsInput, fn func(*DescribeSpotInstanceRequestsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeSpotInstanceRequestsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeSpotInstanceRequestsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeSpotInstanceRequestsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeSpotPriceHistory = "DescribeSpotPriceHistory" // DescribeSpotPriceHistoryRequest generates a "aws/request.Request" representing the // client's request for the DescribeSpotPriceHistory operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18681,7 +13764,7 @@ func (c *EC2) DescribeSpotPriceHistoryRequest(input *DescribeSpotPriceHistoryInp // DescribeSpotPriceHistory API operation for Amazon Elastic Compute Cloud. // // Describes the Spot price history. For more information, see Spot Instance -// Pricing History (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-spot-instances-history.html) +// Pricing History (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-spot-instances-history.html) // in the Amazon EC2 User Guide for Linux Instances. // // When you specify a start and end time, this operation returns the prices @@ -18728,7 +13811,7 @@ func (c *EC2) DescribeSpotPriceHistoryWithContext(ctx aws.Context, input *Descri // // Example iterating over at most 3 pages of a DescribeSpotPriceHistory operation. // pageNum := 0 // err := client.DescribeSpotPriceHistoryPages(params, -// func(page *ec2.DescribeSpotPriceHistoryOutput, lastPage bool) bool { +// func(page *DescribeSpotPriceHistoryOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -18772,7 +13855,7 @@ const opDescribeStaleSecurityGroups = "DescribeStaleSecurityGroups" // DescribeStaleSecurityGroupsRequest generates a "aws/request.Request" representing the // client's request for the DescribeStaleSecurityGroups operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18798,12 +13881,6 @@ func (c *EC2) DescribeStaleSecurityGroupsRequest(input *DescribeStaleSecurityGro Name: opDescribeStaleSecurityGroups, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -18817,10 +13894,10 @@ func (c *EC2) DescribeStaleSecurityGroupsRequest(input *DescribeStaleSecurityGro // DescribeStaleSecurityGroups API operation for Amazon Elastic Compute Cloud. // -// [VPC only] Describes the stale security group rules for security groups in -// a specified VPC. Rules are stale when they reference a deleted security group -// in a peer VPC, or a security group in a peer VPC for which the VPC peering -// connection has been deleted. +// [EC2-VPC only] Describes the stale security group rules for security groups +// in a specified VPC. Rules are stale when they reference a deleted security +// group in a peer VPC, or a security group in a peer VPC for which the VPC +// peering connection has been deleted. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -18850,62 +13927,12 @@ func (c *EC2) DescribeStaleSecurityGroupsWithContext(ctx aws.Context, input *Des return out, req.Send() } -// DescribeStaleSecurityGroupsPages iterates over the pages of a DescribeStaleSecurityGroups operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeStaleSecurityGroups method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeStaleSecurityGroups operation. -// pageNum := 0 -// err := client.DescribeStaleSecurityGroupsPages(params, -// func(page *ec2.DescribeStaleSecurityGroupsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeStaleSecurityGroupsPages(input *DescribeStaleSecurityGroupsInput, fn func(*DescribeStaleSecurityGroupsOutput, bool) bool) error { - return c.DescribeStaleSecurityGroupsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeStaleSecurityGroupsPagesWithContext same as DescribeStaleSecurityGroupsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeStaleSecurityGroupsPagesWithContext(ctx aws.Context, input *DescribeStaleSecurityGroupsInput, fn func(*DescribeStaleSecurityGroupsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeStaleSecurityGroupsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeStaleSecurityGroupsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeStaleSecurityGroupsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeSubnets = "DescribeSubnets" // DescribeSubnetsRequest generates a "aws/request.Request" representing the // client's request for the DescribeSubnets operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -18931,12 +13958,6 @@ func (c *EC2) DescribeSubnetsRequest(input *DescribeSubnetsInput) (req *request. Name: opDescribeSubnets, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -18952,7 +13973,7 @@ func (c *EC2) DescribeSubnetsRequest(input *DescribeSubnetsInput) (req *request. // // Describes one or more of your subnets. // -// For more information, see Your VPC and Subnets (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html) +// For more information, see Your VPC and Subnets (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Subnets.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -18983,62 +14004,12 @@ func (c *EC2) DescribeSubnetsWithContext(ctx aws.Context, input *DescribeSubnets return out, req.Send() } -// DescribeSubnetsPages iterates over the pages of a DescribeSubnets operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeSubnets method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeSubnets operation. -// pageNum := 0 -// err := client.DescribeSubnetsPages(params, -// func(page *ec2.DescribeSubnetsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeSubnetsPages(input *DescribeSubnetsInput, fn func(*DescribeSubnetsOutput, bool) bool) error { - return c.DescribeSubnetsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeSubnetsPagesWithContext same as DescribeSubnetsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeSubnetsPagesWithContext(ctx aws.Context, input *DescribeSubnetsInput, fn func(*DescribeSubnetsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeSubnetsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeSubnetsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeSubnetsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeTags = "DescribeTags" // DescribeTagsRequest generates a "aws/request.Request" representing the // client's request for the DescribeTags operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -19083,9 +14054,9 @@ func (c *EC2) DescribeTagsRequest(input *DescribeTagsInput) (req *request.Reques // DescribeTags API operation for Amazon Elastic Compute Cloud. // -// Describes the specified tags for your EC2 resources. +// Describes one or more of the tags for your EC2 resources. // -// For more information about tags, see Tagging Your Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) +// For more information about tags, see Tagging Your Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -19127,7 +14098,7 @@ func (c *EC2) DescribeTagsWithContext(ctx aws.Context, input *DescribeTagsInput, // // Example iterating over at most 3 pages of a DescribeTags operation. // pageNum := 0 // err := client.DescribeTagsPages(params, -// func(page *ec2.DescribeTagsOutput, lastPage bool) bool { +// func(page *DescribeTagsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -19166,929 +14137,12 @@ func (c *EC2) DescribeTagsPagesWithContext(ctx aws.Context, input *DescribeTagsI return p.Err() } -const opDescribeTrafficMirrorFilters = "DescribeTrafficMirrorFilters" - -// DescribeTrafficMirrorFiltersRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTrafficMirrorFilters operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTrafficMirrorFilters for more information on using the DescribeTrafficMirrorFilters -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTrafficMirrorFiltersRequest method. -// req, resp := client.DescribeTrafficMirrorFiltersRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorFilters -func (c *EC2) DescribeTrafficMirrorFiltersRequest(input *DescribeTrafficMirrorFiltersInput) (req *request.Request, output *DescribeTrafficMirrorFiltersOutput) { - op := &request.Operation{ - Name: opDescribeTrafficMirrorFilters, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTrafficMirrorFiltersInput{} - } - - output = &DescribeTrafficMirrorFiltersOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTrafficMirrorFilters API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more Traffic Mirror filters. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTrafficMirrorFilters for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorFilters -func (c *EC2) DescribeTrafficMirrorFilters(input *DescribeTrafficMirrorFiltersInput) (*DescribeTrafficMirrorFiltersOutput, error) { - req, out := c.DescribeTrafficMirrorFiltersRequest(input) - return out, req.Send() -} - -// DescribeTrafficMirrorFiltersWithContext is the same as DescribeTrafficMirrorFilters with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTrafficMirrorFilters for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorFiltersWithContext(ctx aws.Context, input *DescribeTrafficMirrorFiltersInput, opts ...request.Option) (*DescribeTrafficMirrorFiltersOutput, error) { - req, out := c.DescribeTrafficMirrorFiltersRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTrafficMirrorFiltersPages iterates over the pages of a DescribeTrafficMirrorFilters operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTrafficMirrorFilters method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTrafficMirrorFilters operation. -// pageNum := 0 -// err := client.DescribeTrafficMirrorFiltersPages(params, -// func(page *ec2.DescribeTrafficMirrorFiltersOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTrafficMirrorFiltersPages(input *DescribeTrafficMirrorFiltersInput, fn func(*DescribeTrafficMirrorFiltersOutput, bool) bool) error { - return c.DescribeTrafficMirrorFiltersPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTrafficMirrorFiltersPagesWithContext same as DescribeTrafficMirrorFiltersPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorFiltersPagesWithContext(ctx aws.Context, input *DescribeTrafficMirrorFiltersInput, fn func(*DescribeTrafficMirrorFiltersOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTrafficMirrorFiltersInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTrafficMirrorFiltersRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTrafficMirrorFiltersOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTrafficMirrorSessions = "DescribeTrafficMirrorSessions" - -// DescribeTrafficMirrorSessionsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTrafficMirrorSessions operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTrafficMirrorSessions for more information on using the DescribeTrafficMirrorSessions -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTrafficMirrorSessionsRequest method. -// req, resp := client.DescribeTrafficMirrorSessionsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorSessions -func (c *EC2) DescribeTrafficMirrorSessionsRequest(input *DescribeTrafficMirrorSessionsInput) (req *request.Request, output *DescribeTrafficMirrorSessionsOutput) { - op := &request.Operation{ - Name: opDescribeTrafficMirrorSessions, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTrafficMirrorSessionsInput{} - } - - output = &DescribeTrafficMirrorSessionsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTrafficMirrorSessions API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more Traffic Mirror sessions. By default, all Traffic Mirror -// sessions are described. Alternatively, you can filter the results. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTrafficMirrorSessions for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorSessions -func (c *EC2) DescribeTrafficMirrorSessions(input *DescribeTrafficMirrorSessionsInput) (*DescribeTrafficMirrorSessionsOutput, error) { - req, out := c.DescribeTrafficMirrorSessionsRequest(input) - return out, req.Send() -} - -// DescribeTrafficMirrorSessionsWithContext is the same as DescribeTrafficMirrorSessions with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTrafficMirrorSessions for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorSessionsWithContext(ctx aws.Context, input *DescribeTrafficMirrorSessionsInput, opts ...request.Option) (*DescribeTrafficMirrorSessionsOutput, error) { - req, out := c.DescribeTrafficMirrorSessionsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTrafficMirrorSessionsPages iterates over the pages of a DescribeTrafficMirrorSessions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTrafficMirrorSessions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTrafficMirrorSessions operation. -// pageNum := 0 -// err := client.DescribeTrafficMirrorSessionsPages(params, -// func(page *ec2.DescribeTrafficMirrorSessionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTrafficMirrorSessionsPages(input *DescribeTrafficMirrorSessionsInput, fn func(*DescribeTrafficMirrorSessionsOutput, bool) bool) error { - return c.DescribeTrafficMirrorSessionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTrafficMirrorSessionsPagesWithContext same as DescribeTrafficMirrorSessionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorSessionsPagesWithContext(ctx aws.Context, input *DescribeTrafficMirrorSessionsInput, fn func(*DescribeTrafficMirrorSessionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTrafficMirrorSessionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTrafficMirrorSessionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTrafficMirrorSessionsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTrafficMirrorTargets = "DescribeTrafficMirrorTargets" - -// DescribeTrafficMirrorTargetsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTrafficMirrorTargets operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTrafficMirrorTargets for more information on using the DescribeTrafficMirrorTargets -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTrafficMirrorTargetsRequest method. -// req, resp := client.DescribeTrafficMirrorTargetsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorTargets -func (c *EC2) DescribeTrafficMirrorTargetsRequest(input *DescribeTrafficMirrorTargetsInput) (req *request.Request, output *DescribeTrafficMirrorTargetsOutput) { - op := &request.Operation{ - Name: opDescribeTrafficMirrorTargets, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTrafficMirrorTargetsInput{} - } - - output = &DescribeTrafficMirrorTargetsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTrafficMirrorTargets API operation for Amazon Elastic Compute Cloud. -// -// Information about one or more Traffic Mirror targets. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTrafficMirrorTargets for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTrafficMirrorTargets -func (c *EC2) DescribeTrafficMirrorTargets(input *DescribeTrafficMirrorTargetsInput) (*DescribeTrafficMirrorTargetsOutput, error) { - req, out := c.DescribeTrafficMirrorTargetsRequest(input) - return out, req.Send() -} - -// DescribeTrafficMirrorTargetsWithContext is the same as DescribeTrafficMirrorTargets with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTrafficMirrorTargets for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorTargetsWithContext(ctx aws.Context, input *DescribeTrafficMirrorTargetsInput, opts ...request.Option) (*DescribeTrafficMirrorTargetsOutput, error) { - req, out := c.DescribeTrafficMirrorTargetsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTrafficMirrorTargetsPages iterates over the pages of a DescribeTrafficMirrorTargets operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTrafficMirrorTargets method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTrafficMirrorTargets operation. -// pageNum := 0 -// err := client.DescribeTrafficMirrorTargetsPages(params, -// func(page *ec2.DescribeTrafficMirrorTargetsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTrafficMirrorTargetsPages(input *DescribeTrafficMirrorTargetsInput, fn func(*DescribeTrafficMirrorTargetsOutput, bool) bool) error { - return c.DescribeTrafficMirrorTargetsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTrafficMirrorTargetsPagesWithContext same as DescribeTrafficMirrorTargetsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTrafficMirrorTargetsPagesWithContext(ctx aws.Context, input *DescribeTrafficMirrorTargetsInput, fn func(*DescribeTrafficMirrorTargetsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTrafficMirrorTargetsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTrafficMirrorTargetsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTrafficMirrorTargetsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTransitGatewayAttachments = "DescribeTransitGatewayAttachments" - -// DescribeTransitGatewayAttachmentsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTransitGatewayAttachments operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTransitGatewayAttachments for more information on using the DescribeTransitGatewayAttachments -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTransitGatewayAttachmentsRequest method. -// req, resp := client.DescribeTransitGatewayAttachmentsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayAttachments -func (c *EC2) DescribeTransitGatewayAttachmentsRequest(input *DescribeTransitGatewayAttachmentsInput) (req *request.Request, output *DescribeTransitGatewayAttachmentsOutput) { - op := &request.Operation{ - Name: opDescribeTransitGatewayAttachments, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTransitGatewayAttachmentsInput{} - } - - output = &DescribeTransitGatewayAttachmentsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTransitGatewayAttachments API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more attachments between resources and transit gateways. -// By default, all attachments are described. Alternatively, you can filter -// the results by attachment ID, attachment state, resource ID, or resource -// owner. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTransitGatewayAttachments for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayAttachments -func (c *EC2) DescribeTransitGatewayAttachments(input *DescribeTransitGatewayAttachmentsInput) (*DescribeTransitGatewayAttachmentsOutput, error) { - req, out := c.DescribeTransitGatewayAttachmentsRequest(input) - return out, req.Send() -} - -// DescribeTransitGatewayAttachmentsWithContext is the same as DescribeTransitGatewayAttachments with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTransitGatewayAttachments for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayAttachmentsWithContext(ctx aws.Context, input *DescribeTransitGatewayAttachmentsInput, opts ...request.Option) (*DescribeTransitGatewayAttachmentsOutput, error) { - req, out := c.DescribeTransitGatewayAttachmentsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTransitGatewayAttachmentsPages iterates over the pages of a DescribeTransitGatewayAttachments operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTransitGatewayAttachments method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTransitGatewayAttachments operation. -// pageNum := 0 -// err := client.DescribeTransitGatewayAttachmentsPages(params, -// func(page *ec2.DescribeTransitGatewayAttachmentsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTransitGatewayAttachmentsPages(input *DescribeTransitGatewayAttachmentsInput, fn func(*DescribeTransitGatewayAttachmentsOutput, bool) bool) error { - return c.DescribeTransitGatewayAttachmentsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTransitGatewayAttachmentsPagesWithContext same as DescribeTransitGatewayAttachmentsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayAttachmentsPagesWithContext(ctx aws.Context, input *DescribeTransitGatewayAttachmentsInput, fn func(*DescribeTransitGatewayAttachmentsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTransitGatewayAttachmentsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTransitGatewayAttachmentsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTransitGatewayAttachmentsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTransitGatewayRouteTables = "DescribeTransitGatewayRouteTables" - -// DescribeTransitGatewayRouteTablesRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTransitGatewayRouteTables operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTransitGatewayRouteTables for more information on using the DescribeTransitGatewayRouteTables -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTransitGatewayRouteTablesRequest method. -// req, resp := client.DescribeTransitGatewayRouteTablesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayRouteTables -func (c *EC2) DescribeTransitGatewayRouteTablesRequest(input *DescribeTransitGatewayRouteTablesInput) (req *request.Request, output *DescribeTransitGatewayRouteTablesOutput) { - op := &request.Operation{ - Name: opDescribeTransitGatewayRouteTables, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTransitGatewayRouteTablesInput{} - } - - output = &DescribeTransitGatewayRouteTablesOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTransitGatewayRouteTables API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more transit gateway route tables. By default, all transit -// gateway route tables are described. Alternatively, you can filter the results. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTransitGatewayRouteTables for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayRouteTables -func (c *EC2) DescribeTransitGatewayRouteTables(input *DescribeTransitGatewayRouteTablesInput) (*DescribeTransitGatewayRouteTablesOutput, error) { - req, out := c.DescribeTransitGatewayRouteTablesRequest(input) - return out, req.Send() -} - -// DescribeTransitGatewayRouteTablesWithContext is the same as DescribeTransitGatewayRouteTables with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTransitGatewayRouteTables for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayRouteTablesWithContext(ctx aws.Context, input *DescribeTransitGatewayRouteTablesInput, opts ...request.Option) (*DescribeTransitGatewayRouteTablesOutput, error) { - req, out := c.DescribeTransitGatewayRouteTablesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTransitGatewayRouteTablesPages iterates over the pages of a DescribeTransitGatewayRouteTables operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTransitGatewayRouteTables method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTransitGatewayRouteTables operation. -// pageNum := 0 -// err := client.DescribeTransitGatewayRouteTablesPages(params, -// func(page *ec2.DescribeTransitGatewayRouteTablesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTransitGatewayRouteTablesPages(input *DescribeTransitGatewayRouteTablesInput, fn func(*DescribeTransitGatewayRouteTablesOutput, bool) bool) error { - return c.DescribeTransitGatewayRouteTablesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTransitGatewayRouteTablesPagesWithContext same as DescribeTransitGatewayRouteTablesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayRouteTablesPagesWithContext(ctx aws.Context, input *DescribeTransitGatewayRouteTablesInput, fn func(*DescribeTransitGatewayRouteTablesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTransitGatewayRouteTablesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTransitGatewayRouteTablesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTransitGatewayRouteTablesOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTransitGatewayVpcAttachments = "DescribeTransitGatewayVpcAttachments" - -// DescribeTransitGatewayVpcAttachmentsRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTransitGatewayVpcAttachments operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTransitGatewayVpcAttachments for more information on using the DescribeTransitGatewayVpcAttachments -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTransitGatewayVpcAttachmentsRequest method. -// req, resp := client.DescribeTransitGatewayVpcAttachmentsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayVpcAttachments -func (c *EC2) DescribeTransitGatewayVpcAttachmentsRequest(input *DescribeTransitGatewayVpcAttachmentsInput) (req *request.Request, output *DescribeTransitGatewayVpcAttachmentsOutput) { - op := &request.Operation{ - Name: opDescribeTransitGatewayVpcAttachments, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTransitGatewayVpcAttachmentsInput{} - } - - output = &DescribeTransitGatewayVpcAttachmentsOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTransitGatewayVpcAttachments API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more VPC attachments. By default, all VPC attachments are -// described. Alternatively, you can filter the results. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTransitGatewayVpcAttachments for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGatewayVpcAttachments -func (c *EC2) DescribeTransitGatewayVpcAttachments(input *DescribeTransitGatewayVpcAttachmentsInput) (*DescribeTransitGatewayVpcAttachmentsOutput, error) { - req, out := c.DescribeTransitGatewayVpcAttachmentsRequest(input) - return out, req.Send() -} - -// DescribeTransitGatewayVpcAttachmentsWithContext is the same as DescribeTransitGatewayVpcAttachments with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTransitGatewayVpcAttachments for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayVpcAttachmentsWithContext(ctx aws.Context, input *DescribeTransitGatewayVpcAttachmentsInput, opts ...request.Option) (*DescribeTransitGatewayVpcAttachmentsOutput, error) { - req, out := c.DescribeTransitGatewayVpcAttachmentsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTransitGatewayVpcAttachmentsPages iterates over the pages of a DescribeTransitGatewayVpcAttachments operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTransitGatewayVpcAttachments method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTransitGatewayVpcAttachments operation. -// pageNum := 0 -// err := client.DescribeTransitGatewayVpcAttachmentsPages(params, -// func(page *ec2.DescribeTransitGatewayVpcAttachmentsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTransitGatewayVpcAttachmentsPages(input *DescribeTransitGatewayVpcAttachmentsInput, fn func(*DescribeTransitGatewayVpcAttachmentsOutput, bool) bool) error { - return c.DescribeTransitGatewayVpcAttachmentsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTransitGatewayVpcAttachmentsPagesWithContext same as DescribeTransitGatewayVpcAttachmentsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewayVpcAttachmentsPagesWithContext(ctx aws.Context, input *DescribeTransitGatewayVpcAttachmentsInput, fn func(*DescribeTransitGatewayVpcAttachmentsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTransitGatewayVpcAttachmentsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTransitGatewayVpcAttachmentsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTransitGatewayVpcAttachmentsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opDescribeTransitGateways = "DescribeTransitGateways" - -// DescribeTransitGatewaysRequest generates a "aws/request.Request" representing the -// client's request for the DescribeTransitGateways operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DescribeTransitGateways for more information on using the DescribeTransitGateways -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DescribeTransitGatewaysRequest method. -// req, resp := client.DescribeTransitGatewaysRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGateways -func (c *EC2) DescribeTransitGatewaysRequest(input *DescribeTransitGatewaysInput) (req *request.Request, output *DescribeTransitGatewaysOutput) { - op := &request.Operation{ - Name: opDescribeTransitGateways, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &DescribeTransitGatewaysInput{} - } - - output = &DescribeTransitGatewaysOutput{} - req = c.newRequest(op, input, output) - return -} - -// DescribeTransitGateways API operation for Amazon Elastic Compute Cloud. -// -// Describes one or more transit gateways. By default, all transit gateways -// are described. Alternatively, you can filter the results. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DescribeTransitGateways for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DescribeTransitGateways -func (c *EC2) DescribeTransitGateways(input *DescribeTransitGatewaysInput) (*DescribeTransitGatewaysOutput, error) { - req, out := c.DescribeTransitGatewaysRequest(input) - return out, req.Send() -} - -// DescribeTransitGatewaysWithContext is the same as DescribeTransitGateways with the addition of -// the ability to pass a context and additional request options. -// -// See DescribeTransitGateways for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewaysWithContext(ctx aws.Context, input *DescribeTransitGatewaysInput, opts ...request.Option) (*DescribeTransitGatewaysOutput, error) { - req, out := c.DescribeTransitGatewaysRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// DescribeTransitGatewaysPages iterates over the pages of a DescribeTransitGateways operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeTransitGateways method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeTransitGateways operation. -// pageNum := 0 -// err := client.DescribeTransitGatewaysPages(params, -// func(page *ec2.DescribeTransitGatewaysOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeTransitGatewaysPages(input *DescribeTransitGatewaysInput, fn func(*DescribeTransitGatewaysOutput, bool) bool) error { - return c.DescribeTransitGatewaysPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeTransitGatewaysPagesWithContext same as DescribeTransitGatewaysPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeTransitGatewaysPagesWithContext(ctx aws.Context, input *DescribeTransitGatewaysInput, fn func(*DescribeTransitGatewaysOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeTransitGatewaysInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeTransitGatewaysRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeTransitGatewaysOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVolumeAttribute = "DescribeVolumeAttribute" // DescribeVolumeAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumeAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20130,7 +14184,7 @@ func (c *EC2) DescribeVolumeAttributeRequest(input *DescribeVolumeAttributeInput // Describes the specified attribute of the specified volume. You can specify // only one attribute at a time. // -// For more information about EBS volumes, see Amazon EBS Volumes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumes.html) +// For more information about EBS volumes, see Amazon EBS Volumes (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumes.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -20166,7 +14220,7 @@ const opDescribeVolumeStatus = "DescribeVolumeStatus" // DescribeVolumeStatusRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumeStatus operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20229,7 +14283,7 @@ func (c *EC2) DescribeVolumeStatusRequest(input *DescribeVolumeStatusInput) (req // If the status is insufficient-data, then the checks may still be taking place // on your volume at the time. We recommend that you retry the request. For // more information about volume status, see Monitoring the Status of Your Volumes -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-volume-status.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-volume-status.html) // in the Amazon Elastic Compute Cloud User Guide. // // Events: Reflect the cause of a volume status and may require you to take @@ -20287,7 +14341,7 @@ func (c *EC2) DescribeVolumeStatusWithContext(ctx aws.Context, input *DescribeVo // // Example iterating over at most 3 pages of a DescribeVolumeStatus operation. // pageNum := 0 // err := client.DescribeVolumeStatusPages(params, -// func(page *ec2.DescribeVolumeStatusOutput, lastPage bool) bool { +// func(page *DescribeVolumeStatusOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -20331,7 +14385,7 @@ const opDescribeVolumes = "DescribeVolumes" // DescribeVolumesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumes operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20376,7 +14430,7 @@ func (c *EC2) DescribeVolumesRequest(input *DescribeVolumesInput) (req *request. // DescribeVolumes API operation for Amazon Elastic Compute Cloud. // -// Describes the specified EBS volumes or all of your EBS volumes. +// Describes the specified EBS volumes. // // If you are describing a long list of volumes, you can paginate the output // to make the list more manageable. The MaxResults parameter sets the maximum @@ -20385,7 +14439,7 @@ func (c *EC2) DescribeVolumesRequest(input *DescribeVolumesInput) (req *request. // a NextToken value that can be passed to a subsequent DescribeVolumes request // to retrieve the remaining results. // -// For more information about EBS volumes, see Amazon EBS Volumes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumes.html) +// For more information about EBS volumes, see Amazon EBS Volumes (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumes.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -20427,7 +14481,7 @@ func (c *EC2) DescribeVolumesWithContext(ctx aws.Context, input *DescribeVolumes // // Example iterating over at most 3 pages of a DescribeVolumes operation. // pageNum := 0 // err := client.DescribeVolumesPages(params, -// func(page *ec2.DescribeVolumesOutput, lastPage bool) bool { +// func(page *DescribeVolumesOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 @@ -20471,7 +14525,7 @@ const opDescribeVolumesModifications = "DescribeVolumesModifications" // DescribeVolumesModificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVolumesModifications operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20497,12 +14551,6 @@ func (c *EC2) DescribeVolumesModificationsRequest(input *DescribeVolumesModifica Name: opDescribeVolumesModifications, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -20527,8 +14575,8 @@ func (c *EC2) DescribeVolumesModificationsRequest(input *DescribeVolumesModifica // // You can also use CloudWatch Events to check the status of a modification // to an EBS volume. For information about CloudWatch Events, see the Amazon -// CloudWatch Events User Guide (https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/). -// For more information, see Monitoring Volume Modifications" (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#monitoring_mods) +// CloudWatch Events User Guide (http://docs.aws.amazon.com/AmazonCloudWatch/latest/events/). +// For more information, see Monitoring Volume Modifications" (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#monitoring_mods) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -20559,62 +14607,12 @@ func (c *EC2) DescribeVolumesModificationsWithContext(ctx aws.Context, input *De return out, req.Send() } -// DescribeVolumesModificationsPages iterates over the pages of a DescribeVolumesModifications operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVolumesModifications method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVolumesModifications operation. -// pageNum := 0 -// err := client.DescribeVolumesModificationsPages(params, -// func(page *ec2.DescribeVolumesModificationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVolumesModificationsPages(input *DescribeVolumesModificationsInput, fn func(*DescribeVolumesModificationsOutput, bool) bool) error { - return c.DescribeVolumesModificationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVolumesModificationsPagesWithContext same as DescribeVolumesModificationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVolumesModificationsPagesWithContext(ctx aws.Context, input *DescribeVolumesModificationsInput, fn func(*DescribeVolumesModificationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVolumesModificationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVolumesModificationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVolumesModificationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcAttribute = "DescribeVpcAttribute" // DescribeVpcAttributeRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20689,7 +14687,7 @@ const opDescribeVpcClassicLink = "DescribeVpcClassicLink" // DescribeVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcClassicLink operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20763,7 +14761,7 @@ const opDescribeVpcClassicLinkDnsSupport = "DescribeVpcClassicLinkDnsSupport" // DescribeVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcClassicLinkDnsSupport operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20789,12 +14787,6 @@ func (c *EC2) DescribeVpcClassicLinkDnsSupportRequest(input *DescribeVpcClassicL Name: opDescribeVpcClassicLinkDnsSupport, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -20813,7 +14805,7 @@ func (c *EC2) DescribeVpcClassicLinkDnsSupportRequest(input *DescribeVpcClassicL // IP address when addressed from an instance in the VPC to which it's linked. // Similarly, the DNS hostname of an instance in a VPC resolves to its private // IP address when addressed from a linked EC2-Classic instance. For more information, -// see ClassicLink (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) +// see ClassicLink (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -20844,62 +14836,12 @@ func (c *EC2) DescribeVpcClassicLinkDnsSupportWithContext(ctx aws.Context, input return out, req.Send() } -// DescribeVpcClassicLinkDnsSupportPages iterates over the pages of a DescribeVpcClassicLinkDnsSupport operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcClassicLinkDnsSupport method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcClassicLinkDnsSupport operation. -// pageNum := 0 -// err := client.DescribeVpcClassicLinkDnsSupportPages(params, -// func(page *ec2.DescribeVpcClassicLinkDnsSupportOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcClassicLinkDnsSupportPages(input *DescribeVpcClassicLinkDnsSupportInput, fn func(*DescribeVpcClassicLinkDnsSupportOutput, bool) bool) error { - return c.DescribeVpcClassicLinkDnsSupportPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcClassicLinkDnsSupportPagesWithContext same as DescribeVpcClassicLinkDnsSupportPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcClassicLinkDnsSupportPagesWithContext(ctx aws.Context, input *DescribeVpcClassicLinkDnsSupportInput, fn func(*DescribeVpcClassicLinkDnsSupportOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcClassicLinkDnsSupportInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcClassicLinkDnsSupportRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcClassicLinkDnsSupportOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcEndpointConnectionNotifications = "DescribeVpcEndpointConnectionNotifications" // DescribeVpcEndpointConnectionNotificationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointConnectionNotifications operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -20925,12 +14867,6 @@ func (c *EC2) DescribeVpcEndpointConnectionNotificationsRequest(input *DescribeV Name: opDescribeVpcEndpointConnectionNotifications, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -20975,62 +14911,12 @@ func (c *EC2) DescribeVpcEndpointConnectionNotificationsWithContext(ctx aws.Cont return out, req.Send() } -// DescribeVpcEndpointConnectionNotificationsPages iterates over the pages of a DescribeVpcEndpointConnectionNotifications operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcEndpointConnectionNotifications method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcEndpointConnectionNotifications operation. -// pageNum := 0 -// err := client.DescribeVpcEndpointConnectionNotificationsPages(params, -// func(page *ec2.DescribeVpcEndpointConnectionNotificationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcEndpointConnectionNotificationsPages(input *DescribeVpcEndpointConnectionNotificationsInput, fn func(*DescribeVpcEndpointConnectionNotificationsOutput, bool) bool) error { - return c.DescribeVpcEndpointConnectionNotificationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcEndpointConnectionNotificationsPagesWithContext same as DescribeVpcEndpointConnectionNotificationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcEndpointConnectionNotificationsPagesWithContext(ctx aws.Context, input *DescribeVpcEndpointConnectionNotificationsInput, fn func(*DescribeVpcEndpointConnectionNotificationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcEndpointConnectionNotificationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcEndpointConnectionNotificationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcEndpointConnectionNotificationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcEndpointConnections = "DescribeVpcEndpointConnections" // DescribeVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointConnections operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21056,12 +14942,6 @@ func (c *EC2) DescribeVpcEndpointConnectionsRequest(input *DescribeVpcEndpointCo Name: opDescribeVpcEndpointConnections, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21106,62 +14986,12 @@ func (c *EC2) DescribeVpcEndpointConnectionsWithContext(ctx aws.Context, input * return out, req.Send() } -// DescribeVpcEndpointConnectionsPages iterates over the pages of a DescribeVpcEndpointConnections operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcEndpointConnections method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcEndpointConnections operation. -// pageNum := 0 -// err := client.DescribeVpcEndpointConnectionsPages(params, -// func(page *ec2.DescribeVpcEndpointConnectionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcEndpointConnectionsPages(input *DescribeVpcEndpointConnectionsInput, fn func(*DescribeVpcEndpointConnectionsOutput, bool) bool) error { - return c.DescribeVpcEndpointConnectionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcEndpointConnectionsPagesWithContext same as DescribeVpcEndpointConnectionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcEndpointConnectionsPagesWithContext(ctx aws.Context, input *DescribeVpcEndpointConnectionsInput, fn func(*DescribeVpcEndpointConnectionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcEndpointConnectionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcEndpointConnectionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcEndpointConnectionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcEndpointServiceConfigurations = "DescribeVpcEndpointServiceConfigurations" // DescribeVpcEndpointServiceConfigurationsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServiceConfigurations operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21187,12 +15017,6 @@ func (c *EC2) DescribeVpcEndpointServiceConfigurationsRequest(input *DescribeVpc Name: opDescribeVpcEndpointServiceConfigurations, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21236,62 +15060,12 @@ func (c *EC2) DescribeVpcEndpointServiceConfigurationsWithContext(ctx aws.Contex return out, req.Send() } -// DescribeVpcEndpointServiceConfigurationsPages iterates over the pages of a DescribeVpcEndpointServiceConfigurations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcEndpointServiceConfigurations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcEndpointServiceConfigurations operation. -// pageNum := 0 -// err := client.DescribeVpcEndpointServiceConfigurationsPages(params, -// func(page *ec2.DescribeVpcEndpointServiceConfigurationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcEndpointServiceConfigurationsPages(input *DescribeVpcEndpointServiceConfigurationsInput, fn func(*DescribeVpcEndpointServiceConfigurationsOutput, bool) bool) error { - return c.DescribeVpcEndpointServiceConfigurationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcEndpointServiceConfigurationsPagesWithContext same as DescribeVpcEndpointServiceConfigurationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcEndpointServiceConfigurationsPagesWithContext(ctx aws.Context, input *DescribeVpcEndpointServiceConfigurationsInput, fn func(*DescribeVpcEndpointServiceConfigurationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcEndpointServiceConfigurationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcEndpointServiceConfigurationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcEndpointServiceConfigurationsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcEndpointServicePermissions = "DescribeVpcEndpointServicePermissions" // DescribeVpcEndpointServicePermissionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServicePermissions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21317,12 +15091,6 @@ func (c *EC2) DescribeVpcEndpointServicePermissionsRequest(input *DescribeVpcEnd Name: opDescribeVpcEndpointServicePermissions, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21367,62 +15135,12 @@ func (c *EC2) DescribeVpcEndpointServicePermissionsWithContext(ctx aws.Context, return out, req.Send() } -// DescribeVpcEndpointServicePermissionsPages iterates over the pages of a DescribeVpcEndpointServicePermissions operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcEndpointServicePermissions method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcEndpointServicePermissions operation. -// pageNum := 0 -// err := client.DescribeVpcEndpointServicePermissionsPages(params, -// func(page *ec2.DescribeVpcEndpointServicePermissionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcEndpointServicePermissionsPages(input *DescribeVpcEndpointServicePermissionsInput, fn func(*DescribeVpcEndpointServicePermissionsOutput, bool) bool) error { - return c.DescribeVpcEndpointServicePermissionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcEndpointServicePermissionsPagesWithContext same as DescribeVpcEndpointServicePermissionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcEndpointServicePermissionsPagesWithContext(ctx aws.Context, input *DescribeVpcEndpointServicePermissionsInput, fn func(*DescribeVpcEndpointServicePermissionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcEndpointServicePermissionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcEndpointServicePermissionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcEndpointServicePermissionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcEndpointServices = "DescribeVpcEndpointServices" // DescribeVpcEndpointServicesRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpointServices operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21496,7 +15214,7 @@ const opDescribeVpcEndpoints = "DescribeVpcEndpoints" // DescribeVpcEndpointsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcEndpoints operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21522,12 +15240,6 @@ func (c *EC2) DescribeVpcEndpointsRequest(input *DescribeVpcEndpointsInput) (req Name: opDescribeVpcEndpoints, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21571,62 +15283,12 @@ func (c *EC2) DescribeVpcEndpointsWithContext(ctx aws.Context, input *DescribeVp return out, req.Send() } -// DescribeVpcEndpointsPages iterates over the pages of a DescribeVpcEndpoints operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcEndpoints method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcEndpoints operation. -// pageNum := 0 -// err := client.DescribeVpcEndpointsPages(params, -// func(page *ec2.DescribeVpcEndpointsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcEndpointsPages(input *DescribeVpcEndpointsInput, fn func(*DescribeVpcEndpointsOutput, bool) bool) error { - return c.DescribeVpcEndpointsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcEndpointsPagesWithContext same as DescribeVpcEndpointsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcEndpointsPagesWithContext(ctx aws.Context, input *DescribeVpcEndpointsInput, fn func(*DescribeVpcEndpointsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcEndpointsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcEndpointsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcEndpointsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcPeeringConnections = "DescribeVpcPeeringConnections" // DescribeVpcPeeringConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcPeeringConnections operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21652,12 +15314,6 @@ func (c *EC2) DescribeVpcPeeringConnectionsRequest(input *DescribeVpcPeeringConn Name: opDescribeVpcPeeringConnections, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21701,62 +15357,12 @@ func (c *EC2) DescribeVpcPeeringConnectionsWithContext(ctx aws.Context, input *D return out, req.Send() } -// DescribeVpcPeeringConnectionsPages iterates over the pages of a DescribeVpcPeeringConnections operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcPeeringConnections method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcPeeringConnections operation. -// pageNum := 0 -// err := client.DescribeVpcPeeringConnectionsPages(params, -// func(page *ec2.DescribeVpcPeeringConnectionsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcPeeringConnectionsPages(input *DescribeVpcPeeringConnectionsInput, fn func(*DescribeVpcPeeringConnectionsOutput, bool) bool) error { - return c.DescribeVpcPeeringConnectionsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcPeeringConnectionsPagesWithContext same as DescribeVpcPeeringConnectionsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcPeeringConnectionsPagesWithContext(ctx aws.Context, input *DescribeVpcPeeringConnectionsInput, fn func(*DescribeVpcPeeringConnectionsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcPeeringConnectionsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcPeeringConnectionsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcPeeringConnectionsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpcs = "DescribeVpcs" // DescribeVpcsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpcs operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21782,12 +15388,6 @@ func (c *EC2) DescribeVpcsRequest(input *DescribeVpcsInput) (req *request.Reques Name: opDescribeVpcs, HTTPMethod: "POST", HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, } if input == nil { @@ -21831,62 +15431,12 @@ func (c *EC2) DescribeVpcsWithContext(ctx aws.Context, input *DescribeVpcsInput, return out, req.Send() } -// DescribeVpcsPages iterates over the pages of a DescribeVpcs operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See DescribeVpcs method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a DescribeVpcs operation. -// pageNum := 0 -// err := client.DescribeVpcsPages(params, -// func(page *ec2.DescribeVpcsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) DescribeVpcsPages(input *DescribeVpcsInput, fn func(*DescribeVpcsOutput, bool) bool) error { - return c.DescribeVpcsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// DescribeVpcsPagesWithContext same as DescribeVpcsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DescribeVpcsPagesWithContext(ctx aws.Context, input *DescribeVpcsInput, fn func(*DescribeVpcsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *DescribeVpcsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.DescribeVpcsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*DescribeVpcsOutput), !p.HasNextPage()) - } - return p.Err() -} - const opDescribeVpnConnections = "DescribeVpnConnections" // DescribeVpnConnectionsRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpnConnections operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -21927,8 +15477,9 @@ func (c *EC2) DescribeVpnConnectionsRequest(input *DescribeVpnConnectionsInput) // // Describes one or more of your VPN connections. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about VPN connections, see AWS Managed VPN Connections +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) in the +// Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -21963,7 +15514,7 @@ const opDescribeVpnGateways = "DescribeVpnGateways" // DescribeVpnGatewaysRequest generates a "aws/request.Request" representing the // client's request for the DescribeVpnGateways operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22004,8 +15555,9 @@ func (c *EC2) DescribeVpnGatewaysRequest(input *DescribeVpnGatewaysInput) (req * // // Describes one or more of your virtual private gateways. // -// For more information, see AWS Site-to-Site VPN (https://docs.aws.amazon.com/vpn/latest/s2svpn/VPC_VPN.html) -// in the AWS Site-to-Site VPN User Guide. +// For more information about virtual private gateways, see AWS Managed VPN +// Connections (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html) +// in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -22040,7 +15592,7 @@ const opDetachClassicLinkVpc = "DetachClassicLinkVpc" // DetachClassicLinkVpcRequest generates a "aws/request.Request" representing the // client's request for the DetachClassicLinkVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22116,7 +15668,7 @@ const opDetachInternetGateway = "DetachInternetGateway" // DetachInternetGatewayRequest generates a "aws/request.Request" representing the // client's request for the DetachInternetGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22150,7 +15702,8 @@ func (c *EC2) DetachInternetGatewayRequest(input *DetachInternetGatewayInput) (r output = &DetachInternetGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -22193,7 +15746,7 @@ const opDetachNetworkInterface = "DetachNetworkInterface" // DetachNetworkInterfaceRequest generates a "aws/request.Request" representing the // client's request for the DetachNetworkInterface operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22227,7 +15780,8 @@ func (c *EC2) DetachNetworkInterfaceRequest(input *DetachNetworkInterfaceInput) output = &DetachNetworkInterfaceOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -22268,7 +15822,7 @@ const opDetachVolume = "DetachVolume" // DetachVolumeRequest generates a "aws/request.Request" representing the // client's request for the DetachVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22319,7 +15873,7 @@ func (c *EC2) DetachVolumeRequest(input *DetachVolumeInput) (req *request.Reques // When a volume with an AWS Marketplace product code is detached from an instance, // the product code is no longer associated with the instance. // -// For more information, see Detaching an Amazon EBS Volume (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-detaching-volume.html) +// For more information, see Detaching an Amazon EBS Volume (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-detaching-volume.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -22355,7 +15909,7 @@ const opDetachVpnGateway = "DetachVpnGateway" // DetachVpnGatewayRequest generates a "aws/request.Request" representing the // client's request for the DetachVpnGateway operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22389,7 +15943,8 @@ func (c *EC2) DetachVpnGatewayRequest(input *DetachVpnGatewayInput) (req *reques output = &DetachVpnGatewayOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -22432,170 +15987,12 @@ func (c *EC2) DetachVpnGatewayWithContext(ctx aws.Context, input *DetachVpnGatew return out, req.Send() } -const opDisableEbsEncryptionByDefault = "DisableEbsEncryptionByDefault" - -// DisableEbsEncryptionByDefaultRequest generates a "aws/request.Request" representing the -// client's request for the DisableEbsEncryptionByDefault operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DisableEbsEncryptionByDefault for more information on using the DisableEbsEncryptionByDefault -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DisableEbsEncryptionByDefaultRequest method. -// req, resp := client.DisableEbsEncryptionByDefaultRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisableEbsEncryptionByDefault -func (c *EC2) DisableEbsEncryptionByDefaultRequest(input *DisableEbsEncryptionByDefaultInput) (req *request.Request, output *DisableEbsEncryptionByDefaultOutput) { - op := &request.Operation{ - Name: opDisableEbsEncryptionByDefault, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DisableEbsEncryptionByDefaultInput{} - } - - output = &DisableEbsEncryptionByDefaultOutput{} - req = c.newRequest(op, input, output) - return -} - -// DisableEbsEncryptionByDefault API operation for Amazon Elastic Compute Cloud. -// -// Disables EBS encryption by default for your account in the current Region. -// -// After you disable encryption by default, you can still create encrypted volumes -// by enabling encryption when you create each volume. -// -// Disabling encryption by default does not change the encryption status of -// your existing volumes. -// -// For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DisableEbsEncryptionByDefault for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisableEbsEncryptionByDefault -func (c *EC2) DisableEbsEncryptionByDefault(input *DisableEbsEncryptionByDefaultInput) (*DisableEbsEncryptionByDefaultOutput, error) { - req, out := c.DisableEbsEncryptionByDefaultRequest(input) - return out, req.Send() -} - -// DisableEbsEncryptionByDefaultWithContext is the same as DisableEbsEncryptionByDefault with the addition of -// the ability to pass a context and additional request options. -// -// See DisableEbsEncryptionByDefault for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DisableEbsEncryptionByDefaultWithContext(ctx aws.Context, input *DisableEbsEncryptionByDefaultInput, opts ...request.Option) (*DisableEbsEncryptionByDefaultOutput, error) { - req, out := c.DisableEbsEncryptionByDefaultRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opDisableTransitGatewayRouteTablePropagation = "DisableTransitGatewayRouteTablePropagation" - -// DisableTransitGatewayRouteTablePropagationRequest generates a "aws/request.Request" representing the -// client's request for the DisableTransitGatewayRouteTablePropagation operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DisableTransitGatewayRouteTablePropagation for more information on using the DisableTransitGatewayRouteTablePropagation -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DisableTransitGatewayRouteTablePropagationRequest method. -// req, resp := client.DisableTransitGatewayRouteTablePropagationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisableTransitGatewayRouteTablePropagation -func (c *EC2) DisableTransitGatewayRouteTablePropagationRequest(input *DisableTransitGatewayRouteTablePropagationInput) (req *request.Request, output *DisableTransitGatewayRouteTablePropagationOutput) { - op := &request.Operation{ - Name: opDisableTransitGatewayRouteTablePropagation, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DisableTransitGatewayRouteTablePropagationInput{} - } - - output = &DisableTransitGatewayRouteTablePropagationOutput{} - req = c.newRequest(op, input, output) - return -} - -// DisableTransitGatewayRouteTablePropagation API operation for Amazon Elastic Compute Cloud. -// -// Disables the specified resource attachment from propagating routes to the -// specified propagation route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DisableTransitGatewayRouteTablePropagation for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisableTransitGatewayRouteTablePropagation -func (c *EC2) DisableTransitGatewayRouteTablePropagation(input *DisableTransitGatewayRouteTablePropagationInput) (*DisableTransitGatewayRouteTablePropagationOutput, error) { - req, out := c.DisableTransitGatewayRouteTablePropagationRequest(input) - return out, req.Send() -} - -// DisableTransitGatewayRouteTablePropagationWithContext is the same as DisableTransitGatewayRouteTablePropagation with the addition of -// the ability to pass a context and additional request options. -// -// See DisableTransitGatewayRouteTablePropagation for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DisableTransitGatewayRouteTablePropagationWithContext(ctx aws.Context, input *DisableTransitGatewayRouteTablePropagationInput, opts ...request.Option) (*DisableTransitGatewayRouteTablePropagationOutput, error) { - req, out := c.DisableTransitGatewayRouteTablePropagationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDisableVgwRoutePropagation = "DisableVgwRoutePropagation" // DisableVgwRoutePropagationRequest generates a "aws/request.Request" representing the // client's request for the DisableVgwRoutePropagation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22629,7 +16026,8 @@ func (c *EC2) DisableVgwRoutePropagationRequest(input *DisableVgwRoutePropagatio output = &DisableVgwRoutePropagationOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -22671,7 +16069,7 @@ const opDisableVpcClassicLink = "DisableVpcClassicLink" // DisableVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the DisableVpcClassicLink operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22746,7 +16144,7 @@ const opDisableVpcClassicLinkDnsSupport = "DisableVpcClassicLinkDnsSupport" // DisableVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the DisableVpcClassicLinkDnsSupport operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22788,7 +16186,7 @@ func (c *EC2) DisableVpcClassicLinkDnsSupportRequest(input *DisableVpcClassicLin // Disables ClassicLink DNS support for a VPC. If disabled, DNS hostnames resolve // to public IP addresses when addressed between a linked EC2-Classic instance // and instances in the VPC to which it's linked. For more information, see -// ClassicLink (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) +// ClassicLink (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -22824,7 +16222,7 @@ const opDisassociateAddress = "DisassociateAddress" // DisassociateAddressRequest generates a "aws/request.Request" representing the // client's request for the DisassociateAddress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -22858,7 +16256,8 @@ func (c *EC2) DisassociateAddressRequest(input *DisassociateAddressInput) (req * output = &DisassociateAddressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -22868,7 +16267,7 @@ func (c *EC2) DisassociateAddressRequest(input *DisassociateAddressInput) (req * // it's associated with. // // An Elastic IP address is for use in either the EC2-Classic platform or in -// a VPC. For more information, see Elastic IP Addresses (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) +// a VPC. For more information, see Elastic IP Addresses (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html) // in the Amazon Elastic Compute Cloud User Guide. // // This is an idempotent operation. If you perform the operation more than once, @@ -22902,96 +16301,12 @@ func (c *EC2) DisassociateAddressWithContext(ctx aws.Context, input *Disassociat return out, req.Send() } -const opDisassociateClientVpnTargetNetwork = "DisassociateClientVpnTargetNetwork" - -// DisassociateClientVpnTargetNetworkRequest generates a "aws/request.Request" representing the -// client's request for the DisassociateClientVpnTargetNetwork operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DisassociateClientVpnTargetNetwork for more information on using the DisassociateClientVpnTargetNetwork -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DisassociateClientVpnTargetNetworkRequest method. -// req, resp := client.DisassociateClientVpnTargetNetworkRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisassociateClientVpnTargetNetwork -func (c *EC2) DisassociateClientVpnTargetNetworkRequest(input *DisassociateClientVpnTargetNetworkInput) (req *request.Request, output *DisassociateClientVpnTargetNetworkOutput) { - op := &request.Operation{ - Name: opDisassociateClientVpnTargetNetwork, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DisassociateClientVpnTargetNetworkInput{} - } - - output = &DisassociateClientVpnTargetNetworkOutput{} - req = c.newRequest(op, input, output) - return -} - -// DisassociateClientVpnTargetNetwork API operation for Amazon Elastic Compute Cloud. -// -// Disassociates a target network from the specified Client VPN endpoint. When -// you disassociate the last target network from a Client VPN, the following -// happens: -// -// * The route that was automatically added for the VPC is deleted -// -// * All active client connections are terminated -// -// * New client connections are disallowed -// -// * The Client VPN endpoint's status changes to pending-associate -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DisassociateClientVpnTargetNetwork for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisassociateClientVpnTargetNetwork -func (c *EC2) DisassociateClientVpnTargetNetwork(input *DisassociateClientVpnTargetNetworkInput) (*DisassociateClientVpnTargetNetworkOutput, error) { - req, out := c.DisassociateClientVpnTargetNetworkRequest(input) - return out, req.Send() -} - -// DisassociateClientVpnTargetNetworkWithContext is the same as DisassociateClientVpnTargetNetwork with the addition of -// the ability to pass a context and additional request options. -// -// See DisassociateClientVpnTargetNetwork for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DisassociateClientVpnTargetNetworkWithContext(ctx aws.Context, input *DisassociateClientVpnTargetNetworkInput, opts ...request.Option) (*DisassociateClientVpnTargetNetworkOutput, error) { - req, out := c.DisassociateClientVpnTargetNetworkRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDisassociateIamInstanceProfile = "DisassociateIamInstanceProfile" // DisassociateIamInstanceProfileRequest generates a "aws/request.Request" representing the // client's request for the DisassociateIamInstanceProfile operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23067,7 +16382,7 @@ const opDisassociateRouteTable = "DisassociateRouteTable" // DisassociateRouteTableRequest generates a "aws/request.Request" representing the // client's request for the DisassociateRouteTable operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23101,7 +16416,8 @@ func (c *EC2) DisassociateRouteTableRequest(input *DisassociateRouteTableInput) output = &DisassociateRouteTableOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -23111,7 +16427,7 @@ func (c *EC2) DisassociateRouteTableRequest(input *DisassociateRouteTableInput) // // After you perform this action, the subnet no longer uses the routes in the // route table. Instead, it uses the routes in the VPC's main route table. For -// more information about route tables, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// more information about route tables, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -23147,7 +16463,7 @@ const opDisassociateSubnetCidrBlock = "DisassociateSubnetCidrBlock" // DisassociateSubnetCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the DisassociateSubnetCidrBlock operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23218,86 +16534,12 @@ func (c *EC2) DisassociateSubnetCidrBlockWithContext(ctx aws.Context, input *Dis return out, req.Send() } -const opDisassociateTransitGatewayRouteTable = "DisassociateTransitGatewayRouteTable" - -// DisassociateTransitGatewayRouteTableRequest generates a "aws/request.Request" representing the -// client's request for the DisassociateTransitGatewayRouteTable operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See DisassociateTransitGatewayRouteTable for more information on using the DisassociateTransitGatewayRouteTable -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the DisassociateTransitGatewayRouteTableRequest method. -// req, resp := client.DisassociateTransitGatewayRouteTableRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisassociateTransitGatewayRouteTable -func (c *EC2) DisassociateTransitGatewayRouteTableRequest(input *DisassociateTransitGatewayRouteTableInput) (req *request.Request, output *DisassociateTransitGatewayRouteTableOutput) { - op := &request.Operation{ - Name: opDisassociateTransitGatewayRouteTable, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &DisassociateTransitGatewayRouteTableInput{} - } - - output = &DisassociateTransitGatewayRouteTableOutput{} - req = c.newRequest(op, input, output) - return -} - -// DisassociateTransitGatewayRouteTable API operation for Amazon Elastic Compute Cloud. -// -// Disassociates a resource attachment from a transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation DisassociateTransitGatewayRouteTable for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DisassociateTransitGatewayRouteTable -func (c *EC2) DisassociateTransitGatewayRouteTable(input *DisassociateTransitGatewayRouteTableInput) (*DisassociateTransitGatewayRouteTableOutput, error) { - req, out := c.DisassociateTransitGatewayRouteTableRequest(input) - return out, req.Send() -} - -// DisassociateTransitGatewayRouteTableWithContext is the same as DisassociateTransitGatewayRouteTable with the addition of -// the ability to pass a context and additional request options. -// -// See DisassociateTransitGatewayRouteTable for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) DisassociateTransitGatewayRouteTableWithContext(ctx aws.Context, input *DisassociateTransitGatewayRouteTableInput, opts ...request.Option) (*DisassociateTransitGatewayRouteTableOutput, error) { - req, out := c.DisassociateTransitGatewayRouteTableRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opDisassociateVpcCidrBlock = "DisassociateVpcCidrBlock" // DisassociateVpcCidrBlockRequest generates a "aws/request.Request" representing the // client's request for the DisassociateVpcCidrBlock operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23372,177 +16614,12 @@ func (c *EC2) DisassociateVpcCidrBlockWithContext(ctx aws.Context, input *Disass return out, req.Send() } -const opEnableEbsEncryptionByDefault = "EnableEbsEncryptionByDefault" - -// EnableEbsEncryptionByDefaultRequest generates a "aws/request.Request" representing the -// client's request for the EnableEbsEncryptionByDefault operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See EnableEbsEncryptionByDefault for more information on using the EnableEbsEncryptionByDefault -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the EnableEbsEncryptionByDefaultRequest method. -// req, resp := client.EnableEbsEncryptionByDefaultRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/EnableEbsEncryptionByDefault -func (c *EC2) EnableEbsEncryptionByDefaultRequest(input *EnableEbsEncryptionByDefaultInput) (req *request.Request, output *EnableEbsEncryptionByDefaultOutput) { - op := &request.Operation{ - Name: opEnableEbsEncryptionByDefault, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &EnableEbsEncryptionByDefaultInput{} - } - - output = &EnableEbsEncryptionByDefaultOutput{} - req = c.newRequest(op, input, output) - return -} - -// EnableEbsEncryptionByDefault API operation for Amazon Elastic Compute Cloud. -// -// Enables EBS encryption by default for your account in the current Region. -// -// After you enable encryption by default, the EBS volumes that you create are -// are always encrypted, either using the default CMK or the CMK that you specified -// when you created each volume. For more information, see Amazon EBS Encryption -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// You can specify the default CMK for encryption by default using ModifyEbsDefaultKmsKeyId -// or ResetEbsDefaultKmsKeyId. -// -// Enabling encryption by default has no effect on the encryption status of -// your existing volumes. -// -// After you enable encryption by default, you can no longer launch instances -// using instance types that do not support encryption. For more information, -// see Supported Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#EBSEncryption_supported_instances). -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation EnableEbsEncryptionByDefault for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/EnableEbsEncryptionByDefault -func (c *EC2) EnableEbsEncryptionByDefault(input *EnableEbsEncryptionByDefaultInput) (*EnableEbsEncryptionByDefaultOutput, error) { - req, out := c.EnableEbsEncryptionByDefaultRequest(input) - return out, req.Send() -} - -// EnableEbsEncryptionByDefaultWithContext is the same as EnableEbsEncryptionByDefault with the addition of -// the ability to pass a context and additional request options. -// -// See EnableEbsEncryptionByDefault for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) EnableEbsEncryptionByDefaultWithContext(ctx aws.Context, input *EnableEbsEncryptionByDefaultInput, opts ...request.Option) (*EnableEbsEncryptionByDefaultOutput, error) { - req, out := c.EnableEbsEncryptionByDefaultRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opEnableTransitGatewayRouteTablePropagation = "EnableTransitGatewayRouteTablePropagation" - -// EnableTransitGatewayRouteTablePropagationRequest generates a "aws/request.Request" representing the -// client's request for the EnableTransitGatewayRouteTablePropagation operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See EnableTransitGatewayRouteTablePropagation for more information on using the EnableTransitGatewayRouteTablePropagation -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the EnableTransitGatewayRouteTablePropagationRequest method. -// req, resp := client.EnableTransitGatewayRouteTablePropagationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/EnableTransitGatewayRouteTablePropagation -func (c *EC2) EnableTransitGatewayRouteTablePropagationRequest(input *EnableTransitGatewayRouteTablePropagationInput) (req *request.Request, output *EnableTransitGatewayRouteTablePropagationOutput) { - op := &request.Operation{ - Name: opEnableTransitGatewayRouteTablePropagation, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &EnableTransitGatewayRouteTablePropagationInput{} - } - - output = &EnableTransitGatewayRouteTablePropagationOutput{} - req = c.newRequest(op, input, output) - return -} - -// EnableTransitGatewayRouteTablePropagation API operation for Amazon Elastic Compute Cloud. -// -// Enables the specified attachment to propagate routes to the specified propagation -// route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation EnableTransitGatewayRouteTablePropagation for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/EnableTransitGatewayRouteTablePropagation -func (c *EC2) EnableTransitGatewayRouteTablePropagation(input *EnableTransitGatewayRouteTablePropagationInput) (*EnableTransitGatewayRouteTablePropagationOutput, error) { - req, out := c.EnableTransitGatewayRouteTablePropagationRequest(input) - return out, req.Send() -} - -// EnableTransitGatewayRouteTablePropagationWithContext is the same as EnableTransitGatewayRouteTablePropagation with the addition of -// the ability to pass a context and additional request options. -// -// See EnableTransitGatewayRouteTablePropagation for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) EnableTransitGatewayRouteTablePropagationWithContext(ctx aws.Context, input *EnableTransitGatewayRouteTablePropagationInput, opts ...request.Option) (*EnableTransitGatewayRouteTablePropagationOutput, error) { - req, out := c.EnableTransitGatewayRouteTablePropagationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opEnableVgwRoutePropagation = "EnableVgwRoutePropagation" // EnableVgwRoutePropagationRequest generates a "aws/request.Request" representing the // client's request for the EnableVgwRoutePropagation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23576,7 +16653,8 @@ func (c *EC2) EnableVgwRoutePropagationRequest(input *EnableVgwRoutePropagationI output = &EnableVgwRoutePropagationOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -23618,7 +16696,7 @@ const opEnableVolumeIO = "EnableVolumeIO" // EnableVolumeIORequest generates a "aws/request.Request" representing the // client's request for the EnableVolumeIO operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23652,7 +16730,8 @@ func (c *EC2) EnableVolumeIORequest(input *EnableVolumeIOInput) (req *request.Re output = &EnableVolumeIOOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -23694,7 +16773,7 @@ const opEnableVpcClassicLink = "EnableVpcClassicLink" // EnableVpcClassicLinkRequest generates a "aws/request.Request" representing the // client's request for the EnableVpcClassicLink operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23738,7 +16817,7 @@ func (c *EC2) EnableVpcClassicLinkRequest(input *EnableVpcClassicLinkInput) (req // You cannot enable your VPC for ClassicLink if any of your VPC route tables // have existing routes for address ranges within the 10.0.0.0/8 IP address // range, excluding local routes for VPCs in the 10.0.0.0/16 and 10.1.0.0/16 -// IP address ranges. For more information, see ClassicLink (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) +// IP address ranges. For more information, see ClassicLink (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -23774,7 +16853,7 @@ const opEnableVpcClassicLinkDnsSupport = "EnableVpcClassicLinkDnsSupport" // EnableVpcClassicLinkDnsSupportRequest generates a "aws/request.Request" representing the // client's request for the EnableVpcClassicLinkDnsSupport operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -23818,7 +16897,7 @@ func (c *EC2) EnableVpcClassicLinkDnsSupportRequest(input *EnableVpcClassicLinkD // IP address when addressed from an instance in the VPC to which it's linked. // Similarly, the DNS hostname of an instance in a VPC resolves to its private // IP address when addressed from a linked EC2-Classic instance. For more information, -// see ClassicLink (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) +// see ClassicLink (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -23849,240 +16928,12 @@ func (c *EC2) EnableVpcClassicLinkDnsSupportWithContext(ctx aws.Context, input * return out, req.Send() } -const opExportClientVpnClientCertificateRevocationList = "ExportClientVpnClientCertificateRevocationList" - -// ExportClientVpnClientCertificateRevocationListRequest generates a "aws/request.Request" representing the -// client's request for the ExportClientVpnClientCertificateRevocationList operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ExportClientVpnClientCertificateRevocationList for more information on using the ExportClientVpnClientCertificateRevocationList -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ExportClientVpnClientCertificateRevocationListRequest method. -// req, resp := client.ExportClientVpnClientCertificateRevocationListRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportClientVpnClientCertificateRevocationList -func (c *EC2) ExportClientVpnClientCertificateRevocationListRequest(input *ExportClientVpnClientCertificateRevocationListInput) (req *request.Request, output *ExportClientVpnClientCertificateRevocationListOutput) { - op := &request.Operation{ - Name: opExportClientVpnClientCertificateRevocationList, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ExportClientVpnClientCertificateRevocationListInput{} - } - - output = &ExportClientVpnClientCertificateRevocationListOutput{} - req = c.newRequest(op, input, output) - return -} - -// ExportClientVpnClientCertificateRevocationList API operation for Amazon Elastic Compute Cloud. -// -// Downloads the client certificate revocation list for the specified Client -// VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ExportClientVpnClientCertificateRevocationList for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportClientVpnClientCertificateRevocationList -func (c *EC2) ExportClientVpnClientCertificateRevocationList(input *ExportClientVpnClientCertificateRevocationListInput) (*ExportClientVpnClientCertificateRevocationListOutput, error) { - req, out := c.ExportClientVpnClientCertificateRevocationListRequest(input) - return out, req.Send() -} - -// ExportClientVpnClientCertificateRevocationListWithContext is the same as ExportClientVpnClientCertificateRevocationList with the addition of -// the ability to pass a context and additional request options. -// -// See ExportClientVpnClientCertificateRevocationList for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ExportClientVpnClientCertificateRevocationListWithContext(ctx aws.Context, input *ExportClientVpnClientCertificateRevocationListInput, opts ...request.Option) (*ExportClientVpnClientCertificateRevocationListOutput, error) { - req, out := c.ExportClientVpnClientCertificateRevocationListRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opExportClientVpnClientConfiguration = "ExportClientVpnClientConfiguration" - -// ExportClientVpnClientConfigurationRequest generates a "aws/request.Request" representing the -// client's request for the ExportClientVpnClientConfiguration operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ExportClientVpnClientConfiguration for more information on using the ExportClientVpnClientConfiguration -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ExportClientVpnClientConfigurationRequest method. -// req, resp := client.ExportClientVpnClientConfigurationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportClientVpnClientConfiguration -func (c *EC2) ExportClientVpnClientConfigurationRequest(input *ExportClientVpnClientConfigurationInput) (req *request.Request, output *ExportClientVpnClientConfigurationOutput) { - op := &request.Operation{ - Name: opExportClientVpnClientConfiguration, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ExportClientVpnClientConfigurationInput{} - } - - output = &ExportClientVpnClientConfigurationOutput{} - req = c.newRequest(op, input, output) - return -} - -// ExportClientVpnClientConfiguration API operation for Amazon Elastic Compute Cloud. -// -// Downloads the contents of the Client VPN endpoint configuration file for -// the specified Client VPN endpoint. The Client VPN endpoint configuration -// file includes the Client VPN endpoint and certificate information clients -// need to establish a connection with the Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ExportClientVpnClientConfiguration for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportClientVpnClientConfiguration -func (c *EC2) ExportClientVpnClientConfiguration(input *ExportClientVpnClientConfigurationInput) (*ExportClientVpnClientConfigurationOutput, error) { - req, out := c.ExportClientVpnClientConfigurationRequest(input) - return out, req.Send() -} - -// ExportClientVpnClientConfigurationWithContext is the same as ExportClientVpnClientConfiguration with the addition of -// the ability to pass a context and additional request options. -// -// See ExportClientVpnClientConfiguration for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ExportClientVpnClientConfigurationWithContext(ctx aws.Context, input *ExportClientVpnClientConfigurationInput, opts ...request.Option) (*ExportClientVpnClientConfigurationOutput, error) { - req, out := c.ExportClientVpnClientConfigurationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opExportTransitGatewayRoutes = "ExportTransitGatewayRoutes" - -// ExportTransitGatewayRoutesRequest generates a "aws/request.Request" representing the -// client's request for the ExportTransitGatewayRoutes operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ExportTransitGatewayRoutes for more information on using the ExportTransitGatewayRoutes -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ExportTransitGatewayRoutesRequest method. -// req, resp := client.ExportTransitGatewayRoutesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportTransitGatewayRoutes -func (c *EC2) ExportTransitGatewayRoutesRequest(input *ExportTransitGatewayRoutesInput) (req *request.Request, output *ExportTransitGatewayRoutesOutput) { - op := &request.Operation{ - Name: opExportTransitGatewayRoutes, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ExportTransitGatewayRoutesInput{} - } - - output = &ExportTransitGatewayRoutesOutput{} - req = c.newRequest(op, input, output) - return -} - -// ExportTransitGatewayRoutes API operation for Amazon Elastic Compute Cloud. -// -// Exports routes from the specified transit gateway route table to the specified -// S3 bucket. By default, all routes are exported. Alternatively, you can filter -// by CIDR range. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ExportTransitGatewayRoutes for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ExportTransitGatewayRoutes -func (c *EC2) ExportTransitGatewayRoutes(input *ExportTransitGatewayRoutesInput) (*ExportTransitGatewayRoutesOutput, error) { - req, out := c.ExportTransitGatewayRoutesRequest(input) - return out, req.Send() -} - -// ExportTransitGatewayRoutesWithContext is the same as ExportTransitGatewayRoutes with the addition of -// the ability to pass a context and additional request options. -// -// See ExportTransitGatewayRoutes for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ExportTransitGatewayRoutesWithContext(ctx aws.Context, input *ExportTransitGatewayRoutesInput, opts ...request.Option) (*ExportTransitGatewayRoutesOutput, error) { - req, out := c.ExportTransitGatewayRoutesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opGetConsoleOutput = "GetConsoleOutput" // GetConsoleOutputRequest generates a "aws/request.Request" representing the // client's request for the GetConsoleOutput operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24136,7 +16987,7 @@ func (c *EC2) GetConsoleOutputRequest(input *GetConsoleOutputInput) (req *reques // during the instance lifecycle. This option is supported on instance types // that use the Nitro hypervisor. // -// For more information, see Instance Console Output (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-console.html#instance-console-console-output) +// For more information, see Instance Console Output (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-console.html#instance-console-console-output) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -24172,7 +17023,7 @@ const opGetConsoleScreenshot = "GetConsoleScreenshot" // GetConsoleScreenshotRequest generates a "aws/request.Request" representing the // client's request for the GetConsoleScreenshot operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24243,169 +17094,12 @@ func (c *EC2) GetConsoleScreenshotWithContext(ctx aws.Context, input *GetConsole return out, req.Send() } -const opGetEbsDefaultKmsKeyId = "GetEbsDefaultKmsKeyId" - -// GetEbsDefaultKmsKeyIdRequest generates a "aws/request.Request" representing the -// client's request for the GetEbsDefaultKmsKeyId operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetEbsDefaultKmsKeyId for more information on using the GetEbsDefaultKmsKeyId -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetEbsDefaultKmsKeyIdRequest method. -// req, resp := client.GetEbsDefaultKmsKeyIdRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetEbsDefaultKmsKeyId -func (c *EC2) GetEbsDefaultKmsKeyIdRequest(input *GetEbsDefaultKmsKeyIdInput) (req *request.Request, output *GetEbsDefaultKmsKeyIdOutput) { - op := &request.Operation{ - Name: opGetEbsDefaultKmsKeyId, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &GetEbsDefaultKmsKeyIdInput{} - } - - output = &GetEbsDefaultKmsKeyIdOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetEbsDefaultKmsKeyId API operation for Amazon Elastic Compute Cloud. -// -// Describes the default customer master key (CMK) for EBS encryption by default -// for your account in this Region. You can change the default CMK for encryption -// by default using ModifyEbsDefaultKmsKeyId or ResetEbsDefaultKmsKeyId. -// -// For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation GetEbsDefaultKmsKeyId for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetEbsDefaultKmsKeyId -func (c *EC2) GetEbsDefaultKmsKeyId(input *GetEbsDefaultKmsKeyIdInput) (*GetEbsDefaultKmsKeyIdOutput, error) { - req, out := c.GetEbsDefaultKmsKeyIdRequest(input) - return out, req.Send() -} - -// GetEbsDefaultKmsKeyIdWithContext is the same as GetEbsDefaultKmsKeyId with the addition of -// the ability to pass a context and additional request options. -// -// See GetEbsDefaultKmsKeyId for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetEbsDefaultKmsKeyIdWithContext(ctx aws.Context, input *GetEbsDefaultKmsKeyIdInput, opts ...request.Option) (*GetEbsDefaultKmsKeyIdOutput, error) { - req, out := c.GetEbsDefaultKmsKeyIdRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opGetEbsEncryptionByDefault = "GetEbsEncryptionByDefault" - -// GetEbsEncryptionByDefaultRequest generates a "aws/request.Request" representing the -// client's request for the GetEbsEncryptionByDefault operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetEbsEncryptionByDefault for more information on using the GetEbsEncryptionByDefault -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetEbsEncryptionByDefaultRequest method. -// req, resp := client.GetEbsEncryptionByDefaultRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetEbsEncryptionByDefault -func (c *EC2) GetEbsEncryptionByDefaultRequest(input *GetEbsEncryptionByDefaultInput) (req *request.Request, output *GetEbsEncryptionByDefaultOutput) { - op := &request.Operation{ - Name: opGetEbsEncryptionByDefault, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &GetEbsEncryptionByDefaultInput{} - } - - output = &GetEbsEncryptionByDefaultOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetEbsEncryptionByDefault API operation for Amazon Elastic Compute Cloud. -// -// Describes whether EBS encryption by default is enabled for your account in -// the current Region. -// -// For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation GetEbsEncryptionByDefault for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetEbsEncryptionByDefault -func (c *EC2) GetEbsEncryptionByDefault(input *GetEbsEncryptionByDefaultInput) (*GetEbsEncryptionByDefaultOutput, error) { - req, out := c.GetEbsEncryptionByDefaultRequest(input) - return out, req.Send() -} - -// GetEbsEncryptionByDefaultWithContext is the same as GetEbsEncryptionByDefault with the addition of -// the ability to pass a context and additional request options. -// -// See GetEbsEncryptionByDefault for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetEbsEncryptionByDefaultWithContext(ctx aws.Context, input *GetEbsEncryptionByDefaultInput, opts ...request.Option) (*GetEbsEncryptionByDefaultOutput, error) { - req, out := c.GetEbsEncryptionByDefaultRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opGetHostReservationPurchasePreview = "GetHostReservationPurchasePreview" // GetHostReservationPurchasePreviewRequest generates a "aws/request.Request" representing the // client's request for the GetHostReservationPurchasePreview operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24484,7 +17178,7 @@ const opGetLaunchTemplateData = "GetLaunchTemplateData" // GetLaunchTemplateDataRequest generates a "aws/request.Request" representing the // client's request for the GetLaunchTemplateData operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24559,7 +17253,7 @@ const opGetPasswordData = "GetPasswordData" // GetPasswordDataRequest generates a "aws/request.Request" representing the // client's request for the GetPasswordData operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24602,8 +17296,8 @@ func (c *EC2) GetPasswordDataRequest(input *GetPasswordDataInput) (req *request. // // The Windows password is generated at boot by the EC2Config service or EC2Launch // scripts (Windows Server 2016 and later). This usually only happens the first -// time an instance is launched. For more information, see EC2Config (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/UsingConfig_WinAMI.html) -// and EC2Launch (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2launch.html) +// time an instance is launched. For more information, see EC2Config (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/UsingConfig_WinAMI.html) +// and EC2Launch (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2launch.html) // in the Amazon Elastic Compute Cloud User Guide. // // For the EC2Config service, the password is not generated for rebundled AMIs @@ -24650,7 +17344,7 @@ const opGetReservedInstancesExchangeQuote = "GetReservedInstancesExchangeQuote" // GetReservedInstancesExchangeQuoteRequest generates a "aws/request.Request" representing the // client's request for the GetReservedInstancesExchangeQuote operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -24722,483 +17416,12 @@ func (c *EC2) GetReservedInstancesExchangeQuoteWithContext(ctx aws.Context, inpu return out, req.Send() } -const opGetTransitGatewayAttachmentPropagations = "GetTransitGatewayAttachmentPropagations" - -// GetTransitGatewayAttachmentPropagationsRequest generates a "aws/request.Request" representing the -// client's request for the GetTransitGatewayAttachmentPropagations operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetTransitGatewayAttachmentPropagations for more information on using the GetTransitGatewayAttachmentPropagations -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetTransitGatewayAttachmentPropagationsRequest method. -// req, resp := client.GetTransitGatewayAttachmentPropagationsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayAttachmentPropagations -func (c *EC2) GetTransitGatewayAttachmentPropagationsRequest(input *GetTransitGatewayAttachmentPropagationsInput) (req *request.Request, output *GetTransitGatewayAttachmentPropagationsOutput) { - op := &request.Operation{ - Name: opGetTransitGatewayAttachmentPropagations, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &GetTransitGatewayAttachmentPropagationsInput{} - } - - output = &GetTransitGatewayAttachmentPropagationsOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetTransitGatewayAttachmentPropagations API operation for Amazon Elastic Compute Cloud. -// -// Lists the route tables to which the specified resource attachment propagates -// routes. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation GetTransitGatewayAttachmentPropagations for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayAttachmentPropagations -func (c *EC2) GetTransitGatewayAttachmentPropagations(input *GetTransitGatewayAttachmentPropagationsInput) (*GetTransitGatewayAttachmentPropagationsOutput, error) { - req, out := c.GetTransitGatewayAttachmentPropagationsRequest(input) - return out, req.Send() -} - -// GetTransitGatewayAttachmentPropagationsWithContext is the same as GetTransitGatewayAttachmentPropagations with the addition of -// the ability to pass a context and additional request options. -// -// See GetTransitGatewayAttachmentPropagations for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayAttachmentPropagationsWithContext(ctx aws.Context, input *GetTransitGatewayAttachmentPropagationsInput, opts ...request.Option) (*GetTransitGatewayAttachmentPropagationsOutput, error) { - req, out := c.GetTransitGatewayAttachmentPropagationsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// GetTransitGatewayAttachmentPropagationsPages iterates over the pages of a GetTransitGatewayAttachmentPropagations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See GetTransitGatewayAttachmentPropagations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a GetTransitGatewayAttachmentPropagations operation. -// pageNum := 0 -// err := client.GetTransitGatewayAttachmentPropagationsPages(params, -// func(page *ec2.GetTransitGatewayAttachmentPropagationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) GetTransitGatewayAttachmentPropagationsPages(input *GetTransitGatewayAttachmentPropagationsInput, fn func(*GetTransitGatewayAttachmentPropagationsOutput, bool) bool) error { - return c.GetTransitGatewayAttachmentPropagationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// GetTransitGatewayAttachmentPropagationsPagesWithContext same as GetTransitGatewayAttachmentPropagationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayAttachmentPropagationsPagesWithContext(ctx aws.Context, input *GetTransitGatewayAttachmentPropagationsInput, fn func(*GetTransitGatewayAttachmentPropagationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *GetTransitGatewayAttachmentPropagationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetTransitGatewayAttachmentPropagationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*GetTransitGatewayAttachmentPropagationsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opGetTransitGatewayRouteTableAssociations = "GetTransitGatewayRouteTableAssociations" - -// GetTransitGatewayRouteTableAssociationsRequest generates a "aws/request.Request" representing the -// client's request for the GetTransitGatewayRouteTableAssociations operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetTransitGatewayRouteTableAssociations for more information on using the GetTransitGatewayRouteTableAssociations -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetTransitGatewayRouteTableAssociationsRequest method. -// req, resp := client.GetTransitGatewayRouteTableAssociationsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayRouteTableAssociations -func (c *EC2) GetTransitGatewayRouteTableAssociationsRequest(input *GetTransitGatewayRouteTableAssociationsInput) (req *request.Request, output *GetTransitGatewayRouteTableAssociationsOutput) { - op := &request.Operation{ - Name: opGetTransitGatewayRouteTableAssociations, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &GetTransitGatewayRouteTableAssociationsInput{} - } - - output = &GetTransitGatewayRouteTableAssociationsOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetTransitGatewayRouteTableAssociations API operation for Amazon Elastic Compute Cloud. -// -// Gets information about the associations for the specified transit gateway -// route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation GetTransitGatewayRouteTableAssociations for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayRouteTableAssociations -func (c *EC2) GetTransitGatewayRouteTableAssociations(input *GetTransitGatewayRouteTableAssociationsInput) (*GetTransitGatewayRouteTableAssociationsOutput, error) { - req, out := c.GetTransitGatewayRouteTableAssociationsRequest(input) - return out, req.Send() -} - -// GetTransitGatewayRouteTableAssociationsWithContext is the same as GetTransitGatewayRouteTableAssociations with the addition of -// the ability to pass a context and additional request options. -// -// See GetTransitGatewayRouteTableAssociations for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayRouteTableAssociationsWithContext(ctx aws.Context, input *GetTransitGatewayRouteTableAssociationsInput, opts ...request.Option) (*GetTransitGatewayRouteTableAssociationsOutput, error) { - req, out := c.GetTransitGatewayRouteTableAssociationsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// GetTransitGatewayRouteTableAssociationsPages iterates over the pages of a GetTransitGatewayRouteTableAssociations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See GetTransitGatewayRouteTableAssociations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a GetTransitGatewayRouteTableAssociations operation. -// pageNum := 0 -// err := client.GetTransitGatewayRouteTableAssociationsPages(params, -// func(page *ec2.GetTransitGatewayRouteTableAssociationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) GetTransitGatewayRouteTableAssociationsPages(input *GetTransitGatewayRouteTableAssociationsInput, fn func(*GetTransitGatewayRouteTableAssociationsOutput, bool) bool) error { - return c.GetTransitGatewayRouteTableAssociationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// GetTransitGatewayRouteTableAssociationsPagesWithContext same as GetTransitGatewayRouteTableAssociationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayRouteTableAssociationsPagesWithContext(ctx aws.Context, input *GetTransitGatewayRouteTableAssociationsInput, fn func(*GetTransitGatewayRouteTableAssociationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *GetTransitGatewayRouteTableAssociationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetTransitGatewayRouteTableAssociationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*GetTransitGatewayRouteTableAssociationsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opGetTransitGatewayRouteTablePropagations = "GetTransitGatewayRouteTablePropagations" - -// GetTransitGatewayRouteTablePropagationsRequest generates a "aws/request.Request" representing the -// client's request for the GetTransitGatewayRouteTablePropagations operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See GetTransitGatewayRouteTablePropagations for more information on using the GetTransitGatewayRouteTablePropagations -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the GetTransitGatewayRouteTablePropagationsRequest method. -// req, resp := client.GetTransitGatewayRouteTablePropagationsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayRouteTablePropagations -func (c *EC2) GetTransitGatewayRouteTablePropagationsRequest(input *GetTransitGatewayRouteTablePropagationsInput) (req *request.Request, output *GetTransitGatewayRouteTablePropagationsOutput) { - op := &request.Operation{ - Name: opGetTransitGatewayRouteTablePropagations, - HTTPMethod: "POST", - HTTPPath: "/", - Paginator: &request.Paginator{ - InputTokens: []string{"NextToken"}, - OutputTokens: []string{"NextToken"}, - LimitToken: "MaxResults", - TruncationToken: "", - }, - } - - if input == nil { - input = &GetTransitGatewayRouteTablePropagationsInput{} - } - - output = &GetTransitGatewayRouteTablePropagationsOutput{} - req = c.newRequest(op, input, output) - return -} - -// GetTransitGatewayRouteTablePropagations API operation for Amazon Elastic Compute Cloud. -// -// Gets information about the route table propagations for the specified transit -// gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation GetTransitGatewayRouteTablePropagations for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/GetTransitGatewayRouteTablePropagations -func (c *EC2) GetTransitGatewayRouteTablePropagations(input *GetTransitGatewayRouteTablePropagationsInput) (*GetTransitGatewayRouteTablePropagationsOutput, error) { - req, out := c.GetTransitGatewayRouteTablePropagationsRequest(input) - return out, req.Send() -} - -// GetTransitGatewayRouteTablePropagationsWithContext is the same as GetTransitGatewayRouteTablePropagations with the addition of -// the ability to pass a context and additional request options. -// -// See GetTransitGatewayRouteTablePropagations for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayRouteTablePropagationsWithContext(ctx aws.Context, input *GetTransitGatewayRouteTablePropagationsInput, opts ...request.Option) (*GetTransitGatewayRouteTablePropagationsOutput, error) { - req, out := c.GetTransitGatewayRouteTablePropagationsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -// GetTransitGatewayRouteTablePropagationsPages iterates over the pages of a GetTransitGatewayRouteTablePropagations operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See GetTransitGatewayRouteTablePropagations method for more information on how to use this operation. -// -// Note: This operation can generate multiple requests to a service. -// -// // Example iterating over at most 3 pages of a GetTransitGatewayRouteTablePropagations operation. -// pageNum := 0 -// err := client.GetTransitGatewayRouteTablePropagationsPages(params, -// func(page *ec2.GetTransitGatewayRouteTablePropagationsOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -// -func (c *EC2) GetTransitGatewayRouteTablePropagationsPages(input *GetTransitGatewayRouteTablePropagationsInput, fn func(*GetTransitGatewayRouteTablePropagationsOutput, bool) bool) error { - return c.GetTransitGatewayRouteTablePropagationsPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// GetTransitGatewayRouteTablePropagationsPagesWithContext same as GetTransitGatewayRouteTablePropagationsPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) GetTransitGatewayRouteTablePropagationsPagesWithContext(ctx aws.Context, input *GetTransitGatewayRouteTablePropagationsInput, fn func(*GetTransitGatewayRouteTablePropagationsOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *GetTransitGatewayRouteTablePropagationsInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.GetTransitGatewayRouteTablePropagationsRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - cont := true - for p.Next() && cont { - cont = fn(p.Page().(*GetTransitGatewayRouteTablePropagationsOutput), !p.HasNextPage()) - } - return p.Err() -} - -const opImportClientVpnClientCertificateRevocationList = "ImportClientVpnClientCertificateRevocationList" - -// ImportClientVpnClientCertificateRevocationListRequest generates a "aws/request.Request" representing the -// client's request for the ImportClientVpnClientCertificateRevocationList operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ImportClientVpnClientCertificateRevocationList for more information on using the ImportClientVpnClientCertificateRevocationList -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ImportClientVpnClientCertificateRevocationListRequest method. -// req, resp := client.ImportClientVpnClientCertificateRevocationListRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ImportClientVpnClientCertificateRevocationList -func (c *EC2) ImportClientVpnClientCertificateRevocationListRequest(input *ImportClientVpnClientCertificateRevocationListInput) (req *request.Request, output *ImportClientVpnClientCertificateRevocationListOutput) { - op := &request.Operation{ - Name: opImportClientVpnClientCertificateRevocationList, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ImportClientVpnClientCertificateRevocationListInput{} - } - - output = &ImportClientVpnClientCertificateRevocationListOutput{} - req = c.newRequest(op, input, output) - return -} - -// ImportClientVpnClientCertificateRevocationList API operation for Amazon Elastic Compute Cloud. -// -// Uploads a client certificate revocation list to the specified Client VPN -// endpoint. Uploading a client certificate revocation list overwrites the existing -// client certificate revocation list. -// -// Uploading a client certificate revocation list resets existing client connections. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ImportClientVpnClientCertificateRevocationList for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ImportClientVpnClientCertificateRevocationList -func (c *EC2) ImportClientVpnClientCertificateRevocationList(input *ImportClientVpnClientCertificateRevocationListInput) (*ImportClientVpnClientCertificateRevocationListOutput, error) { - req, out := c.ImportClientVpnClientCertificateRevocationListRequest(input) - return out, req.Send() -} - -// ImportClientVpnClientCertificateRevocationListWithContext is the same as ImportClientVpnClientCertificateRevocationList with the addition of -// the ability to pass a context and additional request options. -// -// See ImportClientVpnClientCertificateRevocationList for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ImportClientVpnClientCertificateRevocationListWithContext(ctx aws.Context, input *ImportClientVpnClientCertificateRevocationListInput, opts ...request.Option) (*ImportClientVpnClientCertificateRevocationListOutput, error) { - req, out := c.ImportClientVpnClientCertificateRevocationListRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opImportImage = "ImportImage" // ImportImageRequest generates a "aws/request.Request" representing the // client's request for the ImportImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25239,7 +17462,7 @@ func (c *EC2) ImportImageRequest(input *ImportImageInput) (req *request.Request, // // Import single or multi-volume disk images or EBS snapshots into an Amazon // Machine Image (AMI). For more information, see Importing a VM as an Image -// Using VM Import/Export (https://docs.aws.amazon.com/vm-import/latest/userguide/vmimport-image-import.html) +// Using VM Import/Export (http://docs.aws.amazon.com/vm-import/latest/userguide/vmimport-image-import.html) // in the VM Import/Export User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -25275,7 +17498,7 @@ const opImportInstance = "ImportInstance" // ImportInstanceRequest generates a "aws/request.Request" representing the // client's request for the ImportInstance operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25317,10 +17540,10 @@ func (c *EC2) ImportInstanceRequest(input *ImportInstanceInput) (req *request.Re // Creates an import instance task using metadata from the specified disk image. // ImportInstance only supports single-volume VMs. To import multi-volume VMs, // use ImportImage. For more information, see Importing a Virtual Machine Using -// the Amazon EC2 CLI (https://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ec2-cli-vmimport-export.html). +// the Amazon EC2 CLI (http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ec2-cli-vmimport-export.html). // // For information about the import manifest referenced by this API action, -// see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). +// see VM Import Manifest (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -25355,7 +17578,7 @@ const opImportKeyPair = "ImportKeyPair" // ImportKeyPairRequest generates a "aws/request.Request" representing the // client's request for the ImportKeyPair operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25400,7 +17623,7 @@ func (c *EC2) ImportKeyPairRequest(input *ImportKeyPairInput) (req *request.Requ // you create the key pair and give AWS just the public key. The private key // is never transferred between you and AWS. // -// For more information about key pairs, see Key Pairs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) +// For more information about key pairs, see Key Pairs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -25436,7 +17659,7 @@ const opImportSnapshot = "ImportSnapshot" // ImportSnapshotRequest generates a "aws/request.Request" representing the // client's request for the ImportSnapshot operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25510,7 +17733,7 @@ const opImportVolume = "ImportVolume" // ImportVolumeRequest generates a "aws/request.Request" representing the // client's request for the ImportVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25550,10 +17773,10 @@ func (c *EC2) ImportVolumeRequest(input *ImportVolumeInput) (req *request.Reques // ImportVolume API operation for Amazon Elastic Compute Cloud. // // Creates an import volume task using metadata from the specified disk image.For -// more information, see Importing Disks to Amazon EBS (https://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/importing-your-volumes-into-amazon-ebs.html). +// more information, see Importing Disks to Amazon EBS (http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/importing-your-volumes-into-amazon-ebs.html). // // For information about the import manifest referenced by this API action, -// see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). +// see VM Import Manifest (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -25583,254 +17806,12 @@ func (c *EC2) ImportVolumeWithContext(ctx aws.Context, input *ImportVolumeInput, return out, req.Send() } -const opModifyCapacityReservation = "ModifyCapacityReservation" - -// ModifyCapacityReservationRequest generates a "aws/request.Request" representing the -// client's request for the ModifyCapacityReservation operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyCapacityReservation for more information on using the ModifyCapacityReservation -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyCapacityReservationRequest method. -// req, resp := client.ModifyCapacityReservationRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyCapacityReservation -func (c *EC2) ModifyCapacityReservationRequest(input *ModifyCapacityReservationInput) (req *request.Request, output *ModifyCapacityReservationOutput) { - op := &request.Operation{ - Name: opModifyCapacityReservation, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyCapacityReservationInput{} - } - - output = &ModifyCapacityReservationOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyCapacityReservation API operation for Amazon Elastic Compute Cloud. -// -// Modifies a Capacity Reservation's capacity and the conditions under which -// it is to be released. You cannot change a Capacity Reservation's instance -// type, EBS optimization, instance store settings, platform, Availability Zone, -// or instance eligibility. If you need to modify any of these attributes, we -// recommend that you cancel the Capacity Reservation, and then create a new -// one with the required attributes. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyCapacityReservation for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyCapacityReservation -func (c *EC2) ModifyCapacityReservation(input *ModifyCapacityReservationInput) (*ModifyCapacityReservationOutput, error) { - req, out := c.ModifyCapacityReservationRequest(input) - return out, req.Send() -} - -// ModifyCapacityReservationWithContext is the same as ModifyCapacityReservation with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyCapacityReservation for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyCapacityReservationWithContext(ctx aws.Context, input *ModifyCapacityReservationInput, opts ...request.Option) (*ModifyCapacityReservationOutput, error) { - req, out := c.ModifyCapacityReservationRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opModifyClientVpnEndpoint = "ModifyClientVpnEndpoint" - -// ModifyClientVpnEndpointRequest generates a "aws/request.Request" representing the -// client's request for the ModifyClientVpnEndpoint operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyClientVpnEndpoint for more information on using the ModifyClientVpnEndpoint -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyClientVpnEndpointRequest method. -// req, resp := client.ModifyClientVpnEndpointRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyClientVpnEndpoint -func (c *EC2) ModifyClientVpnEndpointRequest(input *ModifyClientVpnEndpointInput) (req *request.Request, output *ModifyClientVpnEndpointOutput) { - op := &request.Operation{ - Name: opModifyClientVpnEndpoint, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyClientVpnEndpointInput{} - } - - output = &ModifyClientVpnEndpointOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyClientVpnEndpoint API operation for Amazon Elastic Compute Cloud. -// -// Modifies the specified Client VPN endpoint. You can only modify an endpoint's -// server certificate information, client connection logging information, DNS -// server, and description. Modifying the DNS server resets existing client -// connections. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyClientVpnEndpoint for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyClientVpnEndpoint -func (c *EC2) ModifyClientVpnEndpoint(input *ModifyClientVpnEndpointInput) (*ModifyClientVpnEndpointOutput, error) { - req, out := c.ModifyClientVpnEndpointRequest(input) - return out, req.Send() -} - -// ModifyClientVpnEndpointWithContext is the same as ModifyClientVpnEndpoint with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyClientVpnEndpoint for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyClientVpnEndpointWithContext(ctx aws.Context, input *ModifyClientVpnEndpointInput, opts ...request.Option) (*ModifyClientVpnEndpointOutput, error) { - req, out := c.ModifyClientVpnEndpointRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opModifyEbsDefaultKmsKeyId = "ModifyEbsDefaultKmsKeyId" - -// ModifyEbsDefaultKmsKeyIdRequest generates a "aws/request.Request" representing the -// client's request for the ModifyEbsDefaultKmsKeyId operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyEbsDefaultKmsKeyId for more information on using the ModifyEbsDefaultKmsKeyId -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyEbsDefaultKmsKeyIdRequest method. -// req, resp := client.ModifyEbsDefaultKmsKeyIdRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyEbsDefaultKmsKeyId -func (c *EC2) ModifyEbsDefaultKmsKeyIdRequest(input *ModifyEbsDefaultKmsKeyIdInput) (req *request.Request, output *ModifyEbsDefaultKmsKeyIdOutput) { - op := &request.Operation{ - Name: opModifyEbsDefaultKmsKeyId, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyEbsDefaultKmsKeyIdInput{} - } - - output = &ModifyEbsDefaultKmsKeyIdOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyEbsDefaultKmsKeyId API operation for Amazon Elastic Compute Cloud. -// -// Changes the default customer master key (CMK) for EBS encryption by default -// for your account in this Region. -// -// AWS creates a unique AWS managed CMK in each Region for use with encryption -// by default. If you change the default CMK to a customer managed CMK, it is -// used instead of the AWS managed CMK. To reset the default CMK to the AWS -// managed CMK for EBS, use ResetEbsDefaultKmsKeyId. -// -// If you delete or disable the customer managed CMK that you specified for -// use with encryption by default, your instances will fail to launch. -// -// For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyEbsDefaultKmsKeyId for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyEbsDefaultKmsKeyId -func (c *EC2) ModifyEbsDefaultKmsKeyId(input *ModifyEbsDefaultKmsKeyIdInput) (*ModifyEbsDefaultKmsKeyIdOutput, error) { - req, out := c.ModifyEbsDefaultKmsKeyIdRequest(input) - return out, req.Send() -} - -// ModifyEbsDefaultKmsKeyIdWithContext is the same as ModifyEbsDefaultKmsKeyId with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyEbsDefaultKmsKeyId for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyEbsDefaultKmsKeyIdWithContext(ctx aws.Context, input *ModifyEbsDefaultKmsKeyIdInput, opts ...request.Option) (*ModifyEbsDefaultKmsKeyIdOutput, error) { - req, out := c.ModifyEbsDefaultKmsKeyIdRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opModifyFleet = "ModifyFleet" // ModifyFleetRequest generates a "aws/request.Request" representing the // client's request for the ModifyFleet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25906,7 +17887,7 @@ const opModifyFpgaImageAttribute = "ModifyFpgaImageAttribute" // ModifyFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyFpgaImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -25980,7 +17961,7 @@ const opModifyHosts = "ModifyHosts" // ModifyHostsRequest generates a "aws/request.Request" representing the // client's request for the ModifyHosts operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26023,7 +18004,7 @@ func (c *EC2) ModifyHostsRequest(input *ModifyHostsInput) (req *request.Request, // is enabled, any instances that you launch with a tenancy of host but without // a specific host ID are placed onto any available Dedicated Host in your account // that has auto-placement enabled. When auto-placement is disabled, you need -// to provide a host ID to have the instance launch onto a specific host. If +// to provide a host ID ito have the instance launch onto a specific host. If // no host ID is provided, the instance is launched onto a suitable host with // auto-placement enabled. // @@ -26060,7 +18041,7 @@ const opModifyIdFormat = "ModifyIdFormat" // ModifyIdFormatRequest generates a "aws/request.Request" representing the // client's request for the ModifyIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26094,13 +18075,14 @@ func (c *EC2) ModifyIdFormatRequest(input *ModifyIdFormatInput) (req *request.Re output = &ModifyIdFormatOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // ModifyIdFormat API operation for Amazon Elastic Compute Cloud. // -// Modifies the ID format for the specified resource on a per-Region basis. +// Modifies the ID format for the specified resource on a per-region basis. // You can specify that resources should receive longer IDs (17-character IDs) // when they are created. // @@ -26117,7 +18099,7 @@ func (c *EC2) ModifyIdFormatRequest(input *ModifyIdFormatInput) (req *request.Re // to the entire AWS account. By default, an IAM user defaults to the same settings // as the root user. If you're using this action as the root user, then these // settings apply to the entire account, unless an IAM user explicitly overrides -// these settings for themselves. For more information, see Resource IDs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) +// these settings for themselves. For more information, see Resource IDs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) // in the Amazon Elastic Compute Cloud User Guide. // // Resources created with longer IDs are visible to all IAM roles and users, @@ -26157,7 +18139,7 @@ const opModifyIdentityIdFormat = "ModifyIdentityIdFormat" // ModifyIdentityIdFormatRequest generates a "aws/request.Request" representing the // client's request for the ModifyIdentityIdFormat operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26191,7 +18173,8 @@ func (c *EC2) ModifyIdentityIdFormatRequest(input *ModifyIdentityIdFormatInput) output = &ModifyIdentityIdFormatOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -26211,7 +18194,7 @@ func (c *EC2) ModifyIdentityIdFormatRequest(input *ModifyIdentityIdFormatInput) // | security-group | subnet | subnet-cidr-block-association | vpc | vpc-cidr-block-association // | vpc-endpoint | vpc-peering-connection | vpn-connection | vpn-gateway. // -// For more information, see Resource IDs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) +// For more information, see Resource IDs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/resource-ids.html) // in the Amazon Elastic Compute Cloud User Guide. // // This setting applies to the principal specified in the request; it does not @@ -26254,7 +18237,7 @@ const opModifyImageAttribute = "ModifyImageAttribute" // ModifyImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26288,7 +18271,8 @@ func (c *EC2) ModifyImageAttributeRequest(input *ModifyImageAttributeInput) (req output = &ModifyImageAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -26338,7 +18322,7 @@ const opModifyInstanceAttribute = "ModifyInstanceAttribute" // ModifyInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26372,7 +18356,8 @@ func (c *EC2) ModifyInstanceAttributeRequest(input *ModifyInstanceAttributeInput output = &ModifyInstanceAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -26388,7 +18373,7 @@ func (c *EC2) ModifyInstanceAttributeRequest(input *ModifyInstanceAttributeInput // we recommend that you use the ModifyNetworkInterfaceAttribute action. // // To modify some attributes, the instance must be stopped. For more information, -// see Modifying Attributes of a Stopped Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_ChangingAttributesWhileInstanceStopped.html) +// see Modifying Attributes of a Stopped Instance (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_ChangingAttributesWhileInstanceStopped.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -26419,89 +18404,12 @@ func (c *EC2) ModifyInstanceAttributeWithContext(ctx aws.Context, input *ModifyI return out, req.Send() } -const opModifyInstanceCapacityReservationAttributes = "ModifyInstanceCapacityReservationAttributes" - -// ModifyInstanceCapacityReservationAttributesRequest generates a "aws/request.Request" representing the -// client's request for the ModifyInstanceCapacityReservationAttributes operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyInstanceCapacityReservationAttributes for more information on using the ModifyInstanceCapacityReservationAttributes -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyInstanceCapacityReservationAttributesRequest method. -// req, resp := client.ModifyInstanceCapacityReservationAttributesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyInstanceCapacityReservationAttributes -func (c *EC2) ModifyInstanceCapacityReservationAttributesRequest(input *ModifyInstanceCapacityReservationAttributesInput) (req *request.Request, output *ModifyInstanceCapacityReservationAttributesOutput) { - op := &request.Operation{ - Name: opModifyInstanceCapacityReservationAttributes, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyInstanceCapacityReservationAttributesInput{} - } - - output = &ModifyInstanceCapacityReservationAttributesOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyInstanceCapacityReservationAttributes API operation for Amazon Elastic Compute Cloud. -// -// Modifies the Capacity Reservation settings for a stopped instance. Use this -// action to configure an instance to target a specific Capacity Reservation, -// run in any open Capacity Reservation with matching attributes, or run On-Demand -// Instance capacity. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyInstanceCapacityReservationAttributes for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyInstanceCapacityReservationAttributes -func (c *EC2) ModifyInstanceCapacityReservationAttributes(input *ModifyInstanceCapacityReservationAttributesInput) (*ModifyInstanceCapacityReservationAttributesOutput, error) { - req, out := c.ModifyInstanceCapacityReservationAttributesRequest(input) - return out, req.Send() -} - -// ModifyInstanceCapacityReservationAttributesWithContext is the same as ModifyInstanceCapacityReservationAttributes with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyInstanceCapacityReservationAttributes for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyInstanceCapacityReservationAttributesWithContext(ctx aws.Context, input *ModifyInstanceCapacityReservationAttributesInput, opts ...request.Option) (*ModifyInstanceCapacityReservationAttributesOutput, error) { - req, out := c.ModifyInstanceCapacityReservationAttributesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opModifyInstanceCreditSpecification = "ModifyInstanceCreditSpecification" // ModifyInstanceCreditSpecificationRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstanceCreditSpecification operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26540,10 +18448,10 @@ func (c *EC2) ModifyInstanceCreditSpecificationRequest(input *ModifyInstanceCred // ModifyInstanceCreditSpecification API operation for Amazon Elastic Compute Cloud. // -// Modifies the credit option for CPU usage on a running or stopped T2 or T3 -// instance. The credit options are standard and unlimited. +// Modifies the credit option for CPU usage on a running or stopped T2 instance. +// The credit options are standard and unlimited. // -// For more information, see Burstable Performance Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/burstable-performance-instances.html) +// For more information, see T2 Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -26574,86 +18482,12 @@ func (c *EC2) ModifyInstanceCreditSpecificationWithContext(ctx aws.Context, inpu return out, req.Send() } -const opModifyInstanceEventStartTime = "ModifyInstanceEventStartTime" - -// ModifyInstanceEventStartTimeRequest generates a "aws/request.Request" representing the -// client's request for the ModifyInstanceEventStartTime operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyInstanceEventStartTime for more information on using the ModifyInstanceEventStartTime -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyInstanceEventStartTimeRequest method. -// req, resp := client.ModifyInstanceEventStartTimeRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyInstanceEventStartTime -func (c *EC2) ModifyInstanceEventStartTimeRequest(input *ModifyInstanceEventStartTimeInput) (req *request.Request, output *ModifyInstanceEventStartTimeOutput) { - op := &request.Operation{ - Name: opModifyInstanceEventStartTime, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyInstanceEventStartTimeInput{} - } - - output = &ModifyInstanceEventStartTimeOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyInstanceEventStartTime API operation for Amazon Elastic Compute Cloud. -// -// Modifies the start time for a scheduled Amazon EC2 instance event. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyInstanceEventStartTime for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyInstanceEventStartTime -func (c *EC2) ModifyInstanceEventStartTime(input *ModifyInstanceEventStartTimeInput) (*ModifyInstanceEventStartTimeOutput, error) { - req, out := c.ModifyInstanceEventStartTimeRequest(input) - return out, req.Send() -} - -// ModifyInstanceEventStartTimeWithContext is the same as ModifyInstanceEventStartTime with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyInstanceEventStartTime for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyInstanceEventStartTimeWithContext(ctx aws.Context, input *ModifyInstanceEventStartTimeInput, opts ...request.Option) (*ModifyInstanceEventStartTimeOutput, error) { - req, out := c.ModifyInstanceEventStartTimeRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opModifyInstancePlacement = "ModifyInstancePlacement" // ModifyInstancePlacementRequest generates a "aws/request.Request" representing the // client's request for the ModifyInstancePlacement operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26695,7 +18529,7 @@ func (c *EC2) ModifyInstancePlacementRequest(input *ModifyInstancePlacementInput // Modifies the placement attributes for a specified instance. You can do the // following: // -// * Modify the affinity between an instance and a Dedicated Host (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-overview.html). +// * Modify the affinity between an instance and a Dedicated Host (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-overview.html). // When affinity is set to host and the instance is not associated with a // specific Dedicated Host, the next time the instance is launched, it is // automatically associated with the host on which it lands. If the instance @@ -26706,14 +18540,14 @@ func (c *EC2) ModifyInstancePlacementRequest(input *ModifyInstancePlacementInput // * Change the instance tenancy of an instance from host to dedicated, or // from dedicated to host. // -// * Move an instance to or from a placement group (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html). +// * Move an instance to or from a placement group (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html). // // At least one attribute for affinity, host ID, tenancy, or placement group // name must be specified in the request. Affinity and tenancy can be modified // in the same request. // -// To modify the host ID, tenancy, placement group, or partition for an instance, -// the instance must be in the stopped state. +// To modify the host ID, tenancy, or placement group for an instance, the instance +// must be in the stopped state. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -26748,7 +18582,7 @@ const opModifyLaunchTemplate = "ModifyLaunchTemplate" // ModifyLaunchTemplateRequest generates a "aws/request.Request" representing the // client's request for the ModifyLaunchTemplate operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26824,7 +18658,7 @@ const opModifyNetworkInterfaceAttribute = "ModifyNetworkInterfaceAttribute" // ModifyNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyNetworkInterfaceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26858,15 +18692,15 @@ func (c *EC2) ModifyNetworkInterfaceAttributeRequest(input *ModifyNetworkInterfa output = &ModifyNetworkInterfaceAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // ModifyNetworkInterfaceAttribute API operation for Amazon Elastic Compute Cloud. // // Modifies the specified network interface attribute. You can specify only -// one attribute at a time. You can use this action to attach and detach security -// groups from an existing EC2 instance. +// one attribute at a time. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -26901,7 +18735,7 @@ const opModifyReservedInstances = "ModifyReservedInstances" // ModifyReservedInstancesRequest generates a "aws/request.Request" representing the // client's request for the ModifyReservedInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -26945,7 +18779,7 @@ func (c *EC2) ModifyReservedInstancesRequest(input *ModifyReservedInstancesInput // Instances to be modified must be identical, except for Availability Zone, // network platform, and instance type. // -// For more information, see Modifying Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html) +// For more information, see Modifying Reserved Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-modifying.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -26981,7 +18815,7 @@ const opModifySnapshotAttribute = "ModifySnapshotAttribute" // ModifySnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifySnapshotAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27015,7 +18849,8 @@ func (c *EC2) ModifySnapshotAttributeRequest(input *ModifySnapshotAttributeInput output = &ModifySnapshotAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -27023,15 +18858,16 @@ func (c *EC2) ModifySnapshotAttributeRequest(input *ModifySnapshotAttributeInput // // Adds or removes permission settings for the specified snapshot. You may add // or remove specified AWS account IDs from a snapshot's list of create volume -// permissions, but you cannot do both in a single operation. If you need to -// both add and remove account IDs for a snapshot, you must use multiple operations. +// permissions, but you cannot do both in a single API call. If you need to +// both add and remove account IDs for a snapshot, you must use multiple API +// calls. // // Encrypted snapshots and snapshots with AWS Marketplace product codes cannot // be made public. Snapshots encrypted with your default CMK cannot be shared // with other accounts. // // For more information about modifying snapshot permissions, see Sharing Snapshots -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-modifying-snapshot-permissions.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-modifying-snapshot-permissions.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -27067,7 +18903,7 @@ const opModifySpotFleetRequest = "ModifySpotFleetRequest" // ModifySpotFleetRequestRequest generates a "aws/request.Request" representing the // client's request for the ModifySpotFleetRequest operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27108,8 +18944,6 @@ func (c *EC2) ModifySpotFleetRequestRequest(input *ModifySpotFleetRequestInput) // // Modifies the specified Spot Fleet request. // -// You can only modify a Spot Fleet request of type maintain. -// // While the Spot Fleet request is being modified, it is in the modifying state. // // To scale up your Spot Fleet, increase its target capacity. The Spot Fleet @@ -27165,7 +18999,7 @@ const opModifySubnetAttribute = "ModifySubnetAttribute" // ModifySubnetAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifySubnetAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27199,7 +19033,8 @@ func (c *EC2) ModifySubnetAttributeRequest(input *ModifySubnetAttributeInput) (r output = &ModifySubnetAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -27235,321 +19070,12 @@ func (c *EC2) ModifySubnetAttributeWithContext(ctx aws.Context, input *ModifySub return out, req.Send() } -const opModifyTrafficMirrorFilterNetworkServices = "ModifyTrafficMirrorFilterNetworkServices" - -// ModifyTrafficMirrorFilterNetworkServicesRequest generates a "aws/request.Request" representing the -// client's request for the ModifyTrafficMirrorFilterNetworkServices operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyTrafficMirrorFilterNetworkServices for more information on using the ModifyTrafficMirrorFilterNetworkServices -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyTrafficMirrorFilterNetworkServicesRequest method. -// req, resp := client.ModifyTrafficMirrorFilterNetworkServicesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorFilterNetworkServices -func (c *EC2) ModifyTrafficMirrorFilterNetworkServicesRequest(input *ModifyTrafficMirrorFilterNetworkServicesInput) (req *request.Request, output *ModifyTrafficMirrorFilterNetworkServicesOutput) { - op := &request.Operation{ - Name: opModifyTrafficMirrorFilterNetworkServices, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyTrafficMirrorFilterNetworkServicesInput{} - } - - output = &ModifyTrafficMirrorFilterNetworkServicesOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyTrafficMirrorFilterNetworkServices API operation for Amazon Elastic Compute Cloud. -// -// Allows or restricts mirroring network services. -// -// By default, Amazon DNS network services are not eligible for Traffic Mirror. -// Use AddNetworkServices to add network services to a Traffic Mirror filter. -// When a network service is added to the Traffic Mirror filter, all traffic -// related to that network service will be mirrored. When you no longer want -// to mirror network services, use RemoveNetworkServices to remove the network -// services from the Traffic Mirror filter. -// -// FFor information about filter rule properties, see Network Services (https://docs.aws.amazon.com/vpc/latest/mirroring/traffic-mirroring-considerations.html#traffic-mirroring-network-services) -// in the Traffic Mirroring User Guide . -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyTrafficMirrorFilterNetworkServices for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorFilterNetworkServices -func (c *EC2) ModifyTrafficMirrorFilterNetworkServices(input *ModifyTrafficMirrorFilterNetworkServicesInput) (*ModifyTrafficMirrorFilterNetworkServicesOutput, error) { - req, out := c.ModifyTrafficMirrorFilterNetworkServicesRequest(input) - return out, req.Send() -} - -// ModifyTrafficMirrorFilterNetworkServicesWithContext is the same as ModifyTrafficMirrorFilterNetworkServices with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyTrafficMirrorFilterNetworkServices for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyTrafficMirrorFilterNetworkServicesWithContext(ctx aws.Context, input *ModifyTrafficMirrorFilterNetworkServicesInput, opts ...request.Option) (*ModifyTrafficMirrorFilterNetworkServicesOutput, error) { - req, out := c.ModifyTrafficMirrorFilterNetworkServicesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opModifyTrafficMirrorFilterRule = "ModifyTrafficMirrorFilterRule" - -// ModifyTrafficMirrorFilterRuleRequest generates a "aws/request.Request" representing the -// client's request for the ModifyTrafficMirrorFilterRule operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyTrafficMirrorFilterRule for more information on using the ModifyTrafficMirrorFilterRule -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyTrafficMirrorFilterRuleRequest method. -// req, resp := client.ModifyTrafficMirrorFilterRuleRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorFilterRule -func (c *EC2) ModifyTrafficMirrorFilterRuleRequest(input *ModifyTrafficMirrorFilterRuleInput) (req *request.Request, output *ModifyTrafficMirrorFilterRuleOutput) { - op := &request.Operation{ - Name: opModifyTrafficMirrorFilterRule, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyTrafficMirrorFilterRuleInput{} - } - - output = &ModifyTrafficMirrorFilterRuleOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyTrafficMirrorFilterRule API operation for Amazon Elastic Compute Cloud. -// -// Modifies the specified Traffic Mirror rule. -// -// DestinationCidrBlock and SourceCidrBlock must both be an IPv4 range or an -// IPv6 range. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyTrafficMirrorFilterRule for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorFilterRule -func (c *EC2) ModifyTrafficMirrorFilterRule(input *ModifyTrafficMirrorFilterRuleInput) (*ModifyTrafficMirrorFilterRuleOutput, error) { - req, out := c.ModifyTrafficMirrorFilterRuleRequest(input) - return out, req.Send() -} - -// ModifyTrafficMirrorFilterRuleWithContext is the same as ModifyTrafficMirrorFilterRule with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyTrafficMirrorFilterRule for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyTrafficMirrorFilterRuleWithContext(ctx aws.Context, input *ModifyTrafficMirrorFilterRuleInput, opts ...request.Option) (*ModifyTrafficMirrorFilterRuleOutput, error) { - req, out := c.ModifyTrafficMirrorFilterRuleRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opModifyTrafficMirrorSession = "ModifyTrafficMirrorSession" - -// ModifyTrafficMirrorSessionRequest generates a "aws/request.Request" representing the -// client's request for the ModifyTrafficMirrorSession operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyTrafficMirrorSession for more information on using the ModifyTrafficMirrorSession -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyTrafficMirrorSessionRequest method. -// req, resp := client.ModifyTrafficMirrorSessionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorSession -func (c *EC2) ModifyTrafficMirrorSessionRequest(input *ModifyTrafficMirrorSessionInput) (req *request.Request, output *ModifyTrafficMirrorSessionOutput) { - op := &request.Operation{ - Name: opModifyTrafficMirrorSession, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyTrafficMirrorSessionInput{} - } - - output = &ModifyTrafficMirrorSessionOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyTrafficMirrorSession API operation for Amazon Elastic Compute Cloud. -// -// Modifies a Traffic Mirror session. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyTrafficMirrorSession for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTrafficMirrorSession -func (c *EC2) ModifyTrafficMirrorSession(input *ModifyTrafficMirrorSessionInput) (*ModifyTrafficMirrorSessionOutput, error) { - req, out := c.ModifyTrafficMirrorSessionRequest(input) - return out, req.Send() -} - -// ModifyTrafficMirrorSessionWithContext is the same as ModifyTrafficMirrorSession with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyTrafficMirrorSession for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyTrafficMirrorSessionWithContext(ctx aws.Context, input *ModifyTrafficMirrorSessionInput, opts ...request.Option) (*ModifyTrafficMirrorSessionOutput, error) { - req, out := c.ModifyTrafficMirrorSessionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - -const opModifyTransitGatewayVpcAttachment = "ModifyTransitGatewayVpcAttachment" - -// ModifyTransitGatewayVpcAttachmentRequest generates a "aws/request.Request" representing the -// client's request for the ModifyTransitGatewayVpcAttachment operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyTransitGatewayVpcAttachment for more information on using the ModifyTransitGatewayVpcAttachment -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyTransitGatewayVpcAttachmentRequest method. -// req, resp := client.ModifyTransitGatewayVpcAttachmentRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTransitGatewayVpcAttachment -func (c *EC2) ModifyTransitGatewayVpcAttachmentRequest(input *ModifyTransitGatewayVpcAttachmentInput) (req *request.Request, output *ModifyTransitGatewayVpcAttachmentOutput) { - op := &request.Operation{ - Name: opModifyTransitGatewayVpcAttachment, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyTransitGatewayVpcAttachmentInput{} - } - - output = &ModifyTransitGatewayVpcAttachmentOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyTransitGatewayVpcAttachment API operation for Amazon Elastic Compute Cloud. -// -// Modifies the specified VPC attachment. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyTransitGatewayVpcAttachment for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyTransitGatewayVpcAttachment -func (c *EC2) ModifyTransitGatewayVpcAttachment(input *ModifyTransitGatewayVpcAttachmentInput) (*ModifyTransitGatewayVpcAttachmentOutput, error) { - req, out := c.ModifyTransitGatewayVpcAttachmentRequest(input) - return out, req.Send() -} - -// ModifyTransitGatewayVpcAttachmentWithContext is the same as ModifyTransitGatewayVpcAttachment with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyTransitGatewayVpcAttachment for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyTransitGatewayVpcAttachmentWithContext(ctx aws.Context, input *ModifyTransitGatewayVpcAttachmentInput, opts ...request.Option) (*ModifyTransitGatewayVpcAttachmentOutput, error) { - req, out := c.ModifyTransitGatewayVpcAttachmentRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opModifyVolume = "ModifyVolume" // ModifyVolumeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVolume operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27593,29 +19119,29 @@ func (c *EC2) ModifyVolumeRequest(input *ModifyVolumeInput) (req *request.Reques // current-generation EC2 instance type, you may be able to apply these changes // without stopping the instance or detaching the volume from it. For more information // about modifying an EBS volume running Linux, see Modifying the Size, IOPS, -// or Type of an EBS Volume on Linux (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html). +// or Type of an EBS Volume on Linux (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html). // For more information about modifying an EBS volume running Windows, see Modifying -// the Size, IOPS, or Type of an EBS Volume on Windows (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html). +// the Size, IOPS, or Type of an EBS Volume on Windows (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html). // // When you complete a resize operation on your volume, you need to extend the // volume's file-system size to take advantage of the new storage capacity. // For information about extending a Linux file system, see Extending a Linux -// File System (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#recognize-expanded-volume-linux). +// File System (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#recognize-expanded-volume-linux). // For information about extending a Windows file system, see Extending a Windows -// File System (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html#recognize-expanded-volume-windows). +// File System (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html#recognize-expanded-volume-windows). // // You can use CloudWatch Events to check the status of a modification to an // EBS volume. For information about CloudWatch Events, see the Amazon CloudWatch -// Events User Guide (https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/). -// You can also track the status of a modification using DescribeVolumesModifications. -// For information about tracking status changes using either method, see Monitoring -// Volume Modifications (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#monitoring_mods). +// Events User Guide (http://docs.aws.amazon.com/AmazonCloudWatch/latest/events/). +// You can also track the status of a modification using the DescribeVolumesModifications +// API. For information about tracking status changes using either method, see +// Monitoring Volume Modifications (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html#monitoring_mods). // // With previous-generation instance types, resizing an EBS volume may require // detaching and reattaching the volume or stopping and restarting the instance. // For more information, see Modifying the Size, IOPS, or Type of an EBS Volume -// on Linux (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html) -// and Modifying the Size, IOPS, or Type of an EBS Volume on Windows (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html). +// on Linux (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-expand-volume.html) +// and Modifying the Size, IOPS, or Type of an EBS Volume on Windows (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ebs-expand-volume.html). // // If you reach the maximum volume modification rate per volume limit, you will // need to wait at least six hours before applying further modifications to @@ -27654,7 +19180,7 @@ const opModifyVolumeAttribute = "ModifyVolumeAttribute" // ModifyVolumeAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVolumeAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27688,7 +19214,8 @@ func (c *EC2) ModifyVolumeAttributeRequest(input *ModifyVolumeAttributeInput) (r output = &ModifyVolumeAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -27738,7 +19265,7 @@ const opModifyVpcAttribute = "ModifyVpcAttribute" // ModifyVpcAttributeRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27772,7 +19299,8 @@ func (c *EC2) ModifyVpcAttributeRequest(input *ModifyVpcAttributeInput) (req *re output = &ModifyVpcAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -27813,7 +19341,7 @@ const opModifyVpcEndpoint = "ModifyVpcEndpoint" // ModifyVpcEndpointRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpoint operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27854,7 +19382,7 @@ func (c *EC2) ModifyVpcEndpointRequest(input *ModifyVpcEndpointInput) (req *requ // // Modifies attributes of a specified VPC endpoint. The attributes that you // can modify depend on the type of VPC endpoint (interface or gateway). For -// more information, see VPC Endpoints (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-endpoints.html) +// more information, see VPC Endpoints (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-endpoints.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -27890,7 +19418,7 @@ const opModifyVpcEndpointConnectionNotification = "ModifyVpcEndpointConnectionNo // ModifyVpcEndpointConnectionNotificationRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointConnectionNotification operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -27966,7 +19494,7 @@ const opModifyVpcEndpointServiceConfiguration = "ModifyVpcEndpointServiceConfigu // ModifyVpcEndpointServiceConfigurationRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointServiceConfiguration operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28043,7 +19571,7 @@ const opModifyVpcEndpointServicePermissions = "ModifyVpcEndpointServicePermissio // ModifyVpcEndpointServicePermissionsRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcEndpointServicePermissions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28082,7 +19610,7 @@ func (c *EC2) ModifyVpcEndpointServicePermissionsRequest(input *ModifyVpcEndpoin // ModifyVpcEndpointServicePermissions API operation for Amazon Elastic Compute Cloud. // -// Modifies the permissions for your VPC endpoint service (https://docs.aws.amazon.com/vpc/latest/userguide/endpoint-service.html). +// Modifies the permissions for your VPC endpoint service (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/endpoint-service.html). // You can add or remove permissions for service consumers (IAM users, IAM roles, // and AWS accounts) to connect to your endpoint service. // @@ -28124,7 +19652,7 @@ const opModifyVpcPeeringConnectionOptions = "ModifyVpcPeeringConnectionOptions" // ModifyVpcPeeringConnectionOptionsRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcPeeringConnectionOptions operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28176,16 +19704,12 @@ func (c *EC2) ModifyVpcPeeringConnectionOptionsRequest(input *ModifyVpcPeeringCo // * Enable/disable the ability to resolve public DNS hostnames to private // IP addresses when queried from instances in the peer VPC. // -// If the peered VPCs are in the same AWS account, you can enable DNS resolution -// for queries from the local VPC. This ensures that queries from the local -// VPC resolve to private IP addresses in the peer VPC. This option is not available -// if the peered VPCs are in different AWS accounts or different Regions. For -// peered VPCs in different AWS accounts, each AWS account owner must initiate -// a separate request to modify the peering connection options. For inter-region -// peering connections, you must use the Region for the requester VPC to modify -// the requester VPC peering options and the Region for the accepter VPC to -// modify the accepter VPC peering options. To verify which VPCs are the accepter -// and the requester for a VPC peering connection, use the DescribeVpcPeeringConnections +// If the peered VPCs are in different accounts, each owner must initiate a +// separate request to modify the peering connection options, depending on whether +// their VPC was the requester or accepter for the VPC peering connection. If +// the peered VPCs are in the same account, you can modify the requester and +// accepter options in the same request. To confirm which VPC is the accepter +// and requester for a VPC peering connection, use the DescribeVpcPeeringConnections // command. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -28221,7 +19745,7 @@ const opModifyVpcTenancy = "ModifyVpcTenancy" // ModifyVpcTenancyRequest generates a "aws/request.Request" representing the // client's request for the ModifyVpcTenancy operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28268,7 +19792,7 @@ func (c *EC2) ModifyVpcTenancyRequest(input *ModifyVpcTenancyInput) (req *reques // into the VPC have a tenancy of default, unless you specify otherwise during // launch. The tenancy of any existing instances in the VPC is not affected. // -// For more information, see Dedicated Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-instance.html) +// For more information, see Dedicated Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-instance.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -28299,125 +19823,12 @@ func (c *EC2) ModifyVpcTenancyWithContext(ctx aws.Context, input *ModifyVpcTenan return out, req.Send() } -const opModifyVpnConnection = "ModifyVpnConnection" - -// ModifyVpnConnectionRequest generates a "aws/request.Request" representing the -// client's request for the ModifyVpnConnection operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ModifyVpnConnection for more information on using the ModifyVpnConnection -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ModifyVpnConnectionRequest method. -// req, resp := client.ModifyVpnConnectionRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyVpnConnection -func (c *EC2) ModifyVpnConnectionRequest(input *ModifyVpnConnectionInput) (req *request.Request, output *ModifyVpnConnectionOutput) { - op := &request.Operation{ - Name: opModifyVpnConnection, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ModifyVpnConnectionInput{} - } - - output = &ModifyVpnConnectionOutput{} - req = c.newRequest(op, input, output) - return -} - -// ModifyVpnConnection API operation for Amazon Elastic Compute Cloud. -// -// Modifies the target gateway of a AWS Site-to-Site VPN connection. The following -// migration options are available: -// -// * An existing virtual private gateway to a new virtual private gateway -// -// * An existing virtual private gateway to a transit gateway -// -// * An existing transit gateway to a new transit gateway -// -// * An existing transit gateway to a virtual private gateway -// -// Before you perform the migration to the new gateway, you must configure the -// new gateway. Use CreateVpnGateway to create a virtual private gateway, or -// CreateTransitGateway to create a transit gateway. -// -// This step is required when you migrate from a virtual private gateway with -// static routes to a transit gateway. -// -// You must delete the static routes before you migrate to the new gateway. -// -// Keep a copy of the static route before you delete it. You will need to add -// back these routes to the transit gateway after the VPN connection migration -// is complete. -// -// After you migrate to the new gateway, you might need to modify your VPC route -// table. Use CreateRoute and DeleteRoute to make the changes described in VPN -// Gateway Target Modification Required VPC Route Table Updates (https://docs.aws.amazon.com/vpn/latest/s2svpn/modify-vpn-target.html#step-update-routing) -// in the AWS Site-to-Site VPN User Guide. -// -// When the new gateway is a transit gateway, modify the transit gateway route -// table to allow traffic between the VPC and the AWS Site-to-Site VPN connection. -// Use CreateTransitGatewayRoute to add the routes. -// -// If you deleted VPN static routes, you must add the static routes to the transit -// gateway route table. -// -// After you perform this operation, the AWS VPN endpoint's IP addresses on -// the AWS side and the tunnel options remain intact. Your s2slong; connection -// will be temporarily unavailable for approximately 10 minutes while we provision -// the new endpoints -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ModifyVpnConnection for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ModifyVpnConnection -func (c *EC2) ModifyVpnConnection(input *ModifyVpnConnectionInput) (*ModifyVpnConnectionOutput, error) { - req, out := c.ModifyVpnConnectionRequest(input) - return out, req.Send() -} - -// ModifyVpnConnectionWithContext is the same as ModifyVpnConnection with the addition of -// the ability to pass a context and additional request options. -// -// See ModifyVpnConnection for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ModifyVpnConnectionWithContext(ctx aws.Context, input *ModifyVpnConnectionInput, opts ...request.Option) (*ModifyVpnConnectionOutput, error) { - req, out := c.ModifyVpnConnectionRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opMonitorInstances = "MonitorInstances" // MonitorInstancesRequest generates a "aws/request.Request" representing the // client's request for the MonitorInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28458,7 +19869,7 @@ func (c *EC2) MonitorInstancesRequest(input *MonitorInstancesInput) (req *reques // // Enables detailed monitoring for a running instance. Otherwise, basic monitoring // is enabled. For more information, see Monitoring Your Instances and Volumes -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-cloudwatch.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-cloudwatch.html) // in the Amazon Elastic Compute Cloud User Guide. // // To disable detailed monitoring, see . @@ -28496,7 +19907,7 @@ const opMoveAddressToVpc = "MoveAddressToVpc" // MoveAddressToVpcRequest generates a "aws/request.Request" representing the // client's request for the MoveAddressToVpc operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28571,102 +19982,12 @@ func (c *EC2) MoveAddressToVpcWithContext(ctx aws.Context, input *MoveAddressToV return out, req.Send() } -const opProvisionByoipCidr = "ProvisionByoipCidr" - -// ProvisionByoipCidrRequest generates a "aws/request.Request" representing the -// client's request for the ProvisionByoipCidr operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ProvisionByoipCidr for more information on using the ProvisionByoipCidr -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ProvisionByoipCidrRequest method. -// req, resp := client.ProvisionByoipCidrRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ProvisionByoipCidr -func (c *EC2) ProvisionByoipCidrRequest(input *ProvisionByoipCidrInput) (req *request.Request, output *ProvisionByoipCidrOutput) { - op := &request.Operation{ - Name: opProvisionByoipCidr, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ProvisionByoipCidrInput{} - } - - output = &ProvisionByoipCidrOutput{} - req = c.newRequest(op, input, output) - return -} - -// ProvisionByoipCidr API operation for Amazon Elastic Compute Cloud. -// -// Provisions an address range for use with your AWS resources through bring -// your own IP addresses (BYOIP) and creates a corresponding address pool. After -// the address range is provisioned, it is ready to be advertised using AdvertiseByoipCidr. -// -// AWS verifies that you own the address range and are authorized to advertise -// it. You must ensure that the address range is registered to you and that -// you created an RPKI ROA to authorize Amazon ASNs 16509 and 14618 to advertise -// the address range. For more information, see Bring Your Own IP Addresses -// (BYOIP) (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Provisioning an address range is an asynchronous operation, so the call returns -// immediately, but the address range is not ready to use until its status changes -// from pending-provision to provisioned. To monitor the status of an address -// range, use DescribeByoipCidrs. To allocate an Elastic IP address from your -// address pool, use AllocateAddress with either the specific address from the -// address pool or the ID of the address pool. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ProvisionByoipCidr for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ProvisionByoipCidr -func (c *EC2) ProvisionByoipCidr(input *ProvisionByoipCidrInput) (*ProvisionByoipCidrOutput, error) { - req, out := c.ProvisionByoipCidrRequest(input) - return out, req.Send() -} - -// ProvisionByoipCidrWithContext is the same as ProvisionByoipCidr with the addition of -// the ability to pass a context and additional request options. -// -// See ProvisionByoipCidr for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ProvisionByoipCidrWithContext(ctx aws.Context, input *ProvisionByoipCidrInput, opts ...request.Option) (*ProvisionByoipCidrOutput, error) { - req, out := c.ProvisionByoipCidrRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opPurchaseHostReservation = "PurchaseHostReservation" // PurchaseHostReservationRequest generates a "aws/request.Request" representing the // client's request for the PurchaseHostReservation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28743,7 +20064,7 @@ const opPurchaseReservedInstancesOffering = "PurchaseReservedInstancesOffering" // PurchaseReservedInstancesOfferingRequest generates a "aws/request.Request" representing the // client's request for the PurchaseReservedInstancesOffering operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28789,8 +20110,8 @@ func (c *EC2) PurchaseReservedInstancesOfferingRequest(input *PurchaseReservedIn // offerings that match your specifications. After you've purchased a Reserved // Instance, you can check for your new Reserved Instance with DescribeReservedInstances. // -// For more information, see Reserved Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts-on-demand-reserved-instances.html) -// and Reserved Instance Marketplace (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) +// For more information, see Reserved Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/concepts-on-demand-reserved-instances.html) +// and Reserved Instance Marketplace (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ri-market-general.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -28826,7 +20147,7 @@ const opPurchaseScheduledInstances = "PurchaseScheduledInstances" // PurchaseScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the PurchaseScheduledInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28865,7 +20186,7 @@ func (c *EC2) PurchaseScheduledInstancesRequest(input *PurchaseScheduledInstance // PurchaseScheduledInstances API operation for Amazon Elastic Compute Cloud. // -// Purchases the Scheduled Instances with the specified schedule. +// Purchases one or more Scheduled Instances with the specified schedule. // // Scheduled Instances enable you to purchase Amazon EC2 compute capacity by // the hour for a one-year term. Before you can purchase a Scheduled Instance, @@ -28909,7 +20230,7 @@ const opRebootInstances = "RebootInstances" // RebootInstancesRequest generates a "aws/request.Request" representing the // client's request for the RebootInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -28943,13 +20264,14 @@ func (c *EC2) RebootInstancesRequest(input *RebootInstancesInput) (req *request. output = &RebootInstancesOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // RebootInstances API operation for Amazon Elastic Compute Cloud. // -// Requests a reboot of the specified instances. This operation is asynchronous; +// Requests a reboot of one or more instances. This operation is asynchronous; // it only queues a request to reboot the specified instances. The operation // succeeds if the instances are valid and belong to you. Requests to reboot // terminated instances are ignored. @@ -28958,7 +20280,7 @@ func (c *EC2) RebootInstancesRequest(input *RebootInstancesInput) (req *request. // performs a hard reboot. // // For more information about troubleshooting, see Getting Console Output and -// Rebooting Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-console.html) +// Rebooting Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-console.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -28994,7 +20316,7 @@ const opRegisterImage = "RegisterImage" // RegisterImageRequest generates a "aws/request.Request" representing the // client's request for the RegisterImage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29035,7 +20357,7 @@ func (c *EC2) RegisterImageRequest(input *RegisterImageInput) (req *request.Requ // // Registers an AMI. When you're creating an AMI, this is the final step you // must complete before you can launch an instance from the AMI. For more information -// about creating AMIs, see Creating Your Own AMIs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/creating-an-ami.html) +// about creating AMIs, see Creating Your Own AMIs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/creating-an-ami.html) // in the Amazon Elastic Compute Cloud User Guide. // // For Amazon EBS-backed instances, CreateImage creates and registers the AMI @@ -29044,7 +20366,7 @@ func (c *EC2) RegisterImageRequest(input *RegisterImageInput) (req *request.Requ // You can also use RegisterImage to create an Amazon EBS-backed Linux AMI from // a snapshot of a root device volume. You specify the snapshot using the block // device mapping. For more information, see Launching a Linux Instance from -// a Backup (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-launch-snapshot.html) +// a Backup (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-launch-snapshot.html) // in the Amazon Elastic Compute Cloud User Guide. // // You can't register an image where a secondary (non-root) snapshot has AWS @@ -29094,90 +20416,12 @@ func (c *EC2) RegisterImageWithContext(ctx aws.Context, input *RegisterImageInpu return out, req.Send() } -const opRejectTransitGatewayVpcAttachment = "RejectTransitGatewayVpcAttachment" - -// RejectTransitGatewayVpcAttachmentRequest generates a "aws/request.Request" representing the -// client's request for the RejectTransitGatewayVpcAttachment operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See RejectTransitGatewayVpcAttachment for more information on using the RejectTransitGatewayVpcAttachment -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the RejectTransitGatewayVpcAttachmentRequest method. -// req, resp := client.RejectTransitGatewayVpcAttachmentRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/RejectTransitGatewayVpcAttachment -func (c *EC2) RejectTransitGatewayVpcAttachmentRequest(input *RejectTransitGatewayVpcAttachmentInput) (req *request.Request, output *RejectTransitGatewayVpcAttachmentOutput) { - op := &request.Operation{ - Name: opRejectTransitGatewayVpcAttachment, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &RejectTransitGatewayVpcAttachmentInput{} - } - - output = &RejectTransitGatewayVpcAttachmentOutput{} - req = c.newRequest(op, input, output) - return -} - -// RejectTransitGatewayVpcAttachment API operation for Amazon Elastic Compute Cloud. -// -// Rejects a request to attach a VPC to a transit gateway. -// -// The VPC attachment must be in the pendingAcceptance state. Use DescribeTransitGatewayVpcAttachments -// to view your pending VPC attachment requests. Use AcceptTransitGatewayVpcAttachment -// to accept a VPC attachment request. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation RejectTransitGatewayVpcAttachment for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/RejectTransitGatewayVpcAttachment -func (c *EC2) RejectTransitGatewayVpcAttachment(input *RejectTransitGatewayVpcAttachmentInput) (*RejectTransitGatewayVpcAttachmentOutput, error) { - req, out := c.RejectTransitGatewayVpcAttachmentRequest(input) - return out, req.Send() -} - -// RejectTransitGatewayVpcAttachmentWithContext is the same as RejectTransitGatewayVpcAttachment with the addition of -// the ability to pass a context and additional request options. -// -// See RejectTransitGatewayVpcAttachment for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) RejectTransitGatewayVpcAttachmentWithContext(ctx aws.Context, input *RejectTransitGatewayVpcAttachmentInput, opts ...request.Option) (*RejectTransitGatewayVpcAttachmentOutput, error) { - req, out := c.RejectTransitGatewayVpcAttachmentRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opRejectVpcEndpointConnections = "RejectVpcEndpointConnections" // RejectVpcEndpointConnectionsRequest generates a "aws/request.Request" representing the // client's request for the RejectVpcEndpointConnections operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29252,7 +20496,7 @@ const opRejectVpcPeeringConnection = "RejectVpcPeeringConnection" // RejectVpcPeeringConnectionRequest generates a "aws/request.Request" representing the // client's request for the RejectVpcPeeringConnection operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29330,7 +20574,7 @@ const opReleaseAddress = "ReleaseAddress" // ReleaseAddressRequest generates a "aws/request.Request" representing the // client's request for the ReleaseAddress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29364,7 +20608,8 @@ func (c *EC2) ReleaseAddressRequest(input *ReleaseAddressInput) (req *request.Re output = &ReleaseAddressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -29422,7 +20667,7 @@ const opReleaseHosts = "ReleaseHosts" // ReleaseHostsRequest generates a "aws/request.Request" representing the // client's request for the ReleaseHosts operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29464,7 +20709,7 @@ func (c *EC2) ReleaseHostsRequest(input *ReleaseHostsInput) (req *request.Reques // When you no longer want to use an On-Demand Dedicated Host it can be released. // On-Demand billing is stopped and the host goes into released state. The host // ID of Dedicated Hosts that have been released can no longer be specified -// in another request, for example, to modify the host. You must stop or terminate +// in another request, for example, ModifyHosts. You must stop or terminate // all instances on a host before it can be released. // // When Dedicated Hosts are released, it may take some time for them to stop @@ -29506,7 +20751,7 @@ const opReplaceIamInstanceProfileAssociation = "ReplaceIamInstanceProfileAssocia // ReplaceIamInstanceProfileAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceIamInstanceProfileAssociation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29585,7 +20830,7 @@ const opReplaceNetworkAclAssociation = "ReplaceNetworkAclAssociation" // ReplaceNetworkAclAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceNetworkAclAssociation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29626,7 +20871,7 @@ func (c *EC2) ReplaceNetworkAclAssociationRequest(input *ReplaceNetworkAclAssoci // // Changes which network ACL a subnet is associated with. By default when you // create a subnet, it's automatically associated with the default network ACL. -// For more information, see Network ACLs (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_ACLs.html) +// For more information, see Network ACLs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html) // in the Amazon Virtual Private Cloud User Guide. // // This is an idempotent operation. @@ -29664,7 +20909,7 @@ const opReplaceNetworkAclEntry = "ReplaceNetworkAclEntry" // ReplaceNetworkAclEntryRequest generates a "aws/request.Request" representing the // client's request for the ReplaceNetworkAclEntry operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29698,15 +20943,16 @@ func (c *EC2) ReplaceNetworkAclEntryRequest(input *ReplaceNetworkAclEntryInput) output = &ReplaceNetworkAclEntryOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // ReplaceNetworkAclEntry API operation for Amazon Elastic Compute Cloud. // // Replaces an entry (rule) in a network ACL. For more information, see Network -// ACLs (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_ACLs.html) in -// the Amazon Virtual Private Cloud User Guide. +// ACLs (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_ACLs.html) +// in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -29741,7 +20987,7 @@ const opReplaceRoute = "ReplaceRoute" // ReplaceRouteRequest generates a "aws/request.Request" representing the // client's request for the ReplaceRoute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29775,7 +21021,8 @@ func (c *EC2) ReplaceRouteRequest(input *ReplaceRouteInput) (req *request.Reques output = &ReplaceRouteOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -29786,7 +21033,7 @@ func (c *EC2) ReplaceRouteRequest(input *ReplaceRouteInput) (req *request.Reques // instance, NAT gateway, VPC peering connection, network interface, or egress-only // internet gateway. // -// For more information, see Route Tables (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// For more information, see Route Tables (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -29822,7 +21069,7 @@ const opReplaceRouteTableAssociation = "ReplaceRouteTableAssociation" // ReplaceRouteTableAssociationRequest generates a "aws/request.Request" representing the // client's request for the ReplaceRouteTableAssociation operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -29864,7 +21111,7 @@ func (c *EC2) ReplaceRouteTableAssociationRequest(input *ReplaceRouteTableAssoci // Changes the route table associated with a given subnet in a VPC. After the // operation completes, the subnet uses the routes in the new route table it's // associated with. For more information about route tables, see Route Tables -// (https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Route_Tables.html) +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_Route_Tables.html) // in the Amazon Virtual Private Cloud User Guide. // // You can also use ReplaceRouteTableAssociation to change which table is the @@ -29899,86 +21146,12 @@ func (c *EC2) ReplaceRouteTableAssociationWithContext(ctx aws.Context, input *Re return out, req.Send() } -const opReplaceTransitGatewayRoute = "ReplaceTransitGatewayRoute" - -// ReplaceTransitGatewayRouteRequest generates a "aws/request.Request" representing the -// client's request for the ReplaceTransitGatewayRoute operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ReplaceTransitGatewayRoute for more information on using the ReplaceTransitGatewayRoute -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ReplaceTransitGatewayRouteRequest method. -// req, resp := client.ReplaceTransitGatewayRouteRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ReplaceTransitGatewayRoute -func (c *EC2) ReplaceTransitGatewayRouteRequest(input *ReplaceTransitGatewayRouteInput) (req *request.Request, output *ReplaceTransitGatewayRouteOutput) { - op := &request.Operation{ - Name: opReplaceTransitGatewayRoute, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ReplaceTransitGatewayRouteInput{} - } - - output = &ReplaceTransitGatewayRouteOutput{} - req = c.newRequest(op, input, output) - return -} - -// ReplaceTransitGatewayRoute API operation for Amazon Elastic Compute Cloud. -// -// Replaces the specified route in the specified transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ReplaceTransitGatewayRoute for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ReplaceTransitGatewayRoute -func (c *EC2) ReplaceTransitGatewayRoute(input *ReplaceTransitGatewayRouteInput) (*ReplaceTransitGatewayRouteOutput, error) { - req, out := c.ReplaceTransitGatewayRouteRequest(input) - return out, req.Send() -} - -// ReplaceTransitGatewayRouteWithContext is the same as ReplaceTransitGatewayRoute with the addition of -// the ability to pass a context and additional request options. -// -// See ReplaceTransitGatewayRoute for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ReplaceTransitGatewayRouteWithContext(ctx aws.Context, input *ReplaceTransitGatewayRouteInput, opts ...request.Option) (*ReplaceTransitGatewayRouteOutput, error) { - req, out := c.ReplaceTransitGatewayRouteRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opReportInstanceStatus = "ReportInstanceStatus" // ReportInstanceStatusRequest generates a "aws/request.Request" representing the // client's request for the ReportInstanceStatus operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30012,7 +21185,8 @@ func (c *EC2) ReportInstanceStatusRequest(input *ReportInstanceStatusInput) (req output = &ReportInstanceStatusOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -30059,7 +21233,7 @@ const opRequestSpotFleet = "RequestSpotFleet" // RequestSpotFleetRequest generates a "aws/request.Request" representing the // client's request for the RequestSpotFleet operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30121,7 +21295,7 @@ func (c *EC2) RequestSpotFleetRequest(input *RequestSpotFleetInput) (req *reques // types in a Spot Fleet request because only the instance resource type is // supported. // -// For more information, see Spot Fleet Requests (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-requests.html) +// For more information, see Spot Fleet Requests (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-requests.html) // in the Amazon EC2 User Guide for Linux Instances. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -30157,7 +21331,7 @@ const opRequestSpotInstances = "RequestSpotInstances" // RequestSpotInstancesRequest generates a "aws/request.Request" representing the // client's request for the RequestSpotInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30198,7 +21372,7 @@ func (c *EC2) RequestSpotInstancesRequest(input *RequestSpotInstancesInput) (req // // Creates a Spot Instance request. // -// For more information, see Spot Instance Requests (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-requests.html) +// For more information, see Spot Instance Requests (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-requests.html) // in the Amazon EC2 User Guide for Linux Instances. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -30229,92 +21403,12 @@ func (c *EC2) RequestSpotInstancesWithContext(ctx aws.Context, input *RequestSpo return out, req.Send() } -const opResetEbsDefaultKmsKeyId = "ResetEbsDefaultKmsKeyId" - -// ResetEbsDefaultKmsKeyIdRequest generates a "aws/request.Request" representing the -// client's request for the ResetEbsDefaultKmsKeyId operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ResetEbsDefaultKmsKeyId for more information on using the ResetEbsDefaultKmsKeyId -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the ResetEbsDefaultKmsKeyIdRequest method. -// req, resp := client.ResetEbsDefaultKmsKeyIdRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ResetEbsDefaultKmsKeyId -func (c *EC2) ResetEbsDefaultKmsKeyIdRequest(input *ResetEbsDefaultKmsKeyIdInput) (req *request.Request, output *ResetEbsDefaultKmsKeyIdOutput) { - op := &request.Operation{ - Name: opResetEbsDefaultKmsKeyId, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &ResetEbsDefaultKmsKeyIdInput{} - } - - output = &ResetEbsDefaultKmsKeyIdOutput{} - req = c.newRequest(op, input, output) - return -} - -// ResetEbsDefaultKmsKeyId API operation for Amazon Elastic Compute Cloud. -// -// Resets the default customer master key (CMK) for EBS encryption for your -// account in this Region to the AWS managed CMK for EBS. -// -// After resetting the default CMK to the AWS managed CMK, you can continue -// to encrypt by a customer managed CMK by specifying it when you create the -// volume. For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) -// in the Amazon Elastic Compute Cloud User Guide. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation ResetEbsDefaultKmsKeyId for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ResetEbsDefaultKmsKeyId -func (c *EC2) ResetEbsDefaultKmsKeyId(input *ResetEbsDefaultKmsKeyIdInput) (*ResetEbsDefaultKmsKeyIdOutput, error) { - req, out := c.ResetEbsDefaultKmsKeyIdRequest(input) - return out, req.Send() -} - -// ResetEbsDefaultKmsKeyIdWithContext is the same as ResetEbsDefaultKmsKeyId with the addition of -// the ability to pass a context and additional request options. -// -// See ResetEbsDefaultKmsKeyId for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) ResetEbsDefaultKmsKeyIdWithContext(ctx aws.Context, input *ResetEbsDefaultKmsKeyIdInput, opts ...request.Option) (*ResetEbsDefaultKmsKeyIdOutput, error) { - req, out := c.ResetEbsDefaultKmsKeyIdRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opResetFpgaImageAttribute = "ResetFpgaImageAttribute" // ResetFpgaImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetFpgaImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30389,7 +21483,7 @@ const opResetImageAttribute = "ResetImageAttribute" // ResetImageAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetImageAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30423,7 +21517,8 @@ func (c *EC2) ResetImageAttributeRequest(input *ResetImageAttributeInput) (req * output = &ResetImageAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -30466,7 +21561,7 @@ const opResetInstanceAttribute = "ResetInstanceAttribute" // ResetInstanceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetInstanceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30500,7 +21595,8 @@ func (c *EC2) ResetInstanceAttributeRequest(input *ResetInstanceAttributeInput) output = &ResetInstanceAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -30513,7 +21609,7 @@ func (c *EC2) ResetInstanceAttributeRequest(input *ResetInstanceAttributeInput) // The sourceDestCheck attribute controls whether source/destination checking // is enabled. The default value is true, which means checking is enabled. This // value must be false for a NAT instance to perform NAT. For more information, -// see NAT Instances (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) +// see NAT Instances (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) // in the Amazon Virtual Private Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -30549,7 +21645,7 @@ const opResetNetworkInterfaceAttribute = "ResetNetworkInterfaceAttribute" // ResetNetworkInterfaceAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetNetworkInterfaceAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30583,7 +21679,8 @@ func (c *EC2) ResetNetworkInterfaceAttributeRequest(input *ResetNetworkInterface output = &ResetNetworkInterfaceAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -30625,7 +21722,7 @@ const opResetSnapshotAttribute = "ResetSnapshotAttribute" // ResetSnapshotAttributeRequest generates a "aws/request.Request" representing the // client's request for the ResetSnapshotAttribute operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30659,7 +21756,8 @@ func (c *EC2) ResetSnapshotAttributeRequest(input *ResetSnapshotAttributeInput) output = &ResetSnapshotAttributeOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -30668,7 +21766,7 @@ func (c *EC2) ResetSnapshotAttributeRequest(input *ResetSnapshotAttributeInput) // Resets permission settings for the specified snapshot. // // For more information about modifying snapshot permissions, see Sharing Snapshots -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-modifying-snapshot-permissions.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-modifying-snapshot-permissions.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -30704,7 +21802,7 @@ const opRestoreAddressToClassic = "RestoreAddressToClassic" // RestoreAddressToClassicRequest generates a "aws/request.Request" representing the // client's request for the RestoreAddressToClassic operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30776,86 +21874,12 @@ func (c *EC2) RestoreAddressToClassicWithContext(ctx aws.Context, input *Restore return out, req.Send() } -const opRevokeClientVpnIngress = "RevokeClientVpnIngress" - -// RevokeClientVpnIngressRequest generates a "aws/request.Request" representing the -// client's request for the RevokeClientVpnIngress operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See RevokeClientVpnIngress for more information on using the RevokeClientVpnIngress -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the RevokeClientVpnIngressRequest method. -// req, resp := client.RevokeClientVpnIngressRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/RevokeClientVpnIngress -func (c *EC2) RevokeClientVpnIngressRequest(input *RevokeClientVpnIngressInput) (req *request.Request, output *RevokeClientVpnIngressOutput) { - op := &request.Operation{ - Name: opRevokeClientVpnIngress, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &RevokeClientVpnIngressInput{} - } - - output = &RevokeClientVpnIngressOutput{} - req = c.newRequest(op, input, output) - return -} - -// RevokeClientVpnIngress API operation for Amazon Elastic Compute Cloud. -// -// Removes an ingress authorization rule from a Client VPN endpoint. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation RevokeClientVpnIngress for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/RevokeClientVpnIngress -func (c *EC2) RevokeClientVpnIngress(input *RevokeClientVpnIngressInput) (*RevokeClientVpnIngressOutput, error) { - req, out := c.RevokeClientVpnIngressRequest(input) - return out, req.Send() -} - -// RevokeClientVpnIngressWithContext is the same as RevokeClientVpnIngress with the addition of -// the ability to pass a context and additional request options. -// -// See RevokeClientVpnIngress for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) RevokeClientVpnIngressWithContext(ctx aws.Context, input *RevokeClientVpnIngressInput, opts ...request.Option) (*RevokeClientVpnIngressOutput, error) { - req, out := c.RevokeClientVpnIngressRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opRevokeSecurityGroupEgress = "RevokeSecurityGroupEgress" // RevokeSecurityGroupEgressRequest generates a "aws/request.Request" representing the // client's request for the RevokeSecurityGroupEgress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30889,16 +21913,17 @@ func (c *EC2) RevokeSecurityGroupEgressRequest(input *RevokeSecurityGroupEgressI output = &RevokeSecurityGroupEgressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // RevokeSecurityGroupEgress API operation for Amazon Elastic Compute Cloud. // -// [VPC only] Removes the specified egress rules from a security group for EC2-VPC. -// This action doesn't apply to security groups for use in EC2-Classic. To remove -// a rule, the values that you specify (for example, ports) must match the existing -// rule's values exactly. +// [EC2-VPC only] Removes one or more egress rules from a security group for +// EC2-VPC. This action doesn't apply to security groups for use in EC2-Classic. +// To remove a rule, the values that you specify (for example, ports) must match +// the existing rule's values exactly. // // Each rule consists of the protocol and the IPv4 or IPv6 CIDR range or source // security group. For the TCP and UDP protocols, you must also specify the @@ -30942,7 +21967,7 @@ const opRevokeSecurityGroupIngress = "RevokeSecurityGroupIngress" // RevokeSecurityGroupIngressRequest generates a "aws/request.Request" representing the // client's request for the RevokeSecurityGroupIngress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -30976,19 +22001,20 @@ func (c *EC2) RevokeSecurityGroupIngressRequest(input *RevokeSecurityGroupIngres output = &RevokeSecurityGroupIngressOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } // RevokeSecurityGroupIngress API operation for Amazon Elastic Compute Cloud. // -// Removes the specified ingress rules from a security group. To remove a rule, +// Removes one or more ingress rules from a security group. To remove a rule, // the values that you specify (for example, ports) must match the existing // rule's values exactly. // -// [EC2-Classic only] If the values you specify do not match the existing rule's -// values, no error is returned. Use DescribeSecurityGroups to verify that the -// rule has been removed. +// [EC2-Classic security groups only] If the values you specify do not match +// the existing rule's values, no error is returned. Use DescribeSecurityGroups +// to verify that the rule has been removed. // // Each rule consists of the protocol and the CIDR range or source security // group. For the TCP and UDP protocols, you must also specify the destination @@ -31032,7 +22058,7 @@ const opRunInstances = "RunInstances" // RunInstancesRequest generates a "aws/request.Request" representing the // client's request for the RunInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31086,22 +22112,22 @@ func (c *EC2) RunInstancesRequest(input *RunInstancesInput) (req *request.Reques // // * Some instance types must be launched into a VPC. If you do not have // a default VPC, or if you do not specify a subnet ID, the request fails. -// For more information, see Instance Types Available Only in a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-vpc.html#vpc-only-instance-types). +// For more information, see Instance Types Available Only in a VPC (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-vpc.html#vpc-only-instance-types). // // * [EC2-VPC] All instances have a network interface with a primary private // IPv4 address. If you don't specify this address, we choose one from the // IPv4 range of your subnet. // // * Not all instance types support IPv6 addresses. For more information, -// see Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html). +// see Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html). // // * If you don't specify a security group ID, we use the default security -// group. For more information, see Security Groups (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html). +// group. For more information, see Security Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-network-security.html). // // * If any of the AMIs have a product code attached for which the user has // not subscribed, the request fails. // -// You can create a launch template (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-templates.html), +// You can create a launch template (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-templates.html), // which is a resource that contains the parameters to launch an instance. When // you launch an instance using RunInstances, you can specify the launch template // instead of specifying the launch parameters. @@ -31113,17 +22139,17 @@ func (c *EC2) RunInstancesRequest(input *RunInstancesInput) (req *request.Reques // An instance is ready for you to use when it's in the running state. You can // check the state of your instance using DescribeInstances. You can tag instances // and EBS volumes during launch, after launch, or both. For more information, -// see CreateTags and Tagging Your Amazon EC2 Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html). +// see CreateTags and Tagging Your Amazon EC2 Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html). // // Linux instances have access to the public key of the key pair at boot. You // can use this key to provide secure access to the instance. Amazon EC2 public // images use this feature to provide secure access without passwords. For more -// information, see Key Pairs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) +// information, see Key Pairs (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) // in the Amazon Elastic Compute Cloud User Guide. // // For troubleshooting, see What To Do If An Instance Immediately Terminates -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_InstanceStraightToTerminated.html), -// and Troubleshooting Connecting to Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) +// (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_InstanceStraightToTerminated.html), +// and Troubleshooting Connecting to Your Instance (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31159,7 +22185,7 @@ const opRunScheduledInstances = "RunScheduledInstances" // RunScheduledInstancesRequest generates a "aws/request.Request" representing the // client's request for the RunScheduledInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31207,7 +22233,7 @@ func (c *EC2) RunScheduledInstancesRequest(input *RunScheduledInstancesInput) (r // can't stop or reboot a Scheduled Instance, but you can terminate it as needed. // If you terminate a Scheduled Instance before the current scheduled time period // ends, you can launch it again after a few minutes. For more information, -// see Scheduled Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-scheduled-instances.html) +// see Scheduled Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-scheduled-instances.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31238,86 +22264,12 @@ func (c *EC2) RunScheduledInstancesWithContext(ctx aws.Context, input *RunSchedu return out, req.Send() } -const opSearchTransitGatewayRoutes = "SearchTransitGatewayRoutes" - -// SearchTransitGatewayRoutesRequest generates a "aws/request.Request" representing the -// client's request for the SearchTransitGatewayRoutes operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See SearchTransitGatewayRoutes for more information on using the SearchTransitGatewayRoutes -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the SearchTransitGatewayRoutesRequest method. -// req, resp := client.SearchTransitGatewayRoutesRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/SearchTransitGatewayRoutes -func (c *EC2) SearchTransitGatewayRoutesRequest(input *SearchTransitGatewayRoutesInput) (req *request.Request, output *SearchTransitGatewayRoutesOutput) { - op := &request.Operation{ - Name: opSearchTransitGatewayRoutes, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &SearchTransitGatewayRoutesInput{} - } - - output = &SearchTransitGatewayRoutesOutput{} - req = c.newRequest(op, input, output) - return -} - -// SearchTransitGatewayRoutes API operation for Amazon Elastic Compute Cloud. -// -// Searches for routes in the specified transit gateway route table. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation SearchTransitGatewayRoutes for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/SearchTransitGatewayRoutes -func (c *EC2) SearchTransitGatewayRoutes(input *SearchTransitGatewayRoutesInput) (*SearchTransitGatewayRoutesOutput, error) { - req, out := c.SearchTransitGatewayRoutesRequest(input) - return out, req.Send() -} - -// SearchTransitGatewayRoutesWithContext is the same as SearchTransitGatewayRoutes with the addition of -// the ability to pass a context and additional request options. -// -// See SearchTransitGatewayRoutes for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) SearchTransitGatewayRoutesWithContext(ctx aws.Context, input *SearchTransitGatewayRoutesInput, opts ...request.Option) (*SearchTransitGatewayRoutesOutput, error) { - req, out := c.SearchTransitGatewayRoutesRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opStartInstances = "StartInstances" // StartInstancesRequest generates a "aws/request.Request" representing the // client's request for the StartInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31377,7 +22329,7 @@ func (c *EC2) StartInstancesRequest(input *StartInstancesInput) (req *request.Re // Performing this operation on an instance that uses an instance store as its // root device returns an error. // -// For more information, see Stopping Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Stop_Start.html) +// For more information, see Stopping Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Stop_Start.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31413,7 +22365,7 @@ const opStopInstances = "StopInstances" // StopInstancesRequest generates a "aws/request.Request" representing the // client's request for the StopInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31454,12 +22406,6 @@ func (c *EC2) StopInstancesRequest(input *StopInstancesInput) (req *request.Requ // // Stops an Amazon EBS-backed instance. // -// You can use the Stop action to hibernate an instance if the instance is enabled -// for hibernation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#enabling-hibernation) -// and it meets the hibernation prerequisites (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#hibernating-prerequisites). -// For more information, see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) -// in the Amazon Elastic Compute Cloud User Guide. -// // We don't charge usage for a stopped instance, or data transfer fees; however, // your root partition Amazon EBS volume remains and continues to persist your // data, and you are charged for Amazon EBS volume usage. Every time you start @@ -31470,31 +22416,26 @@ func (c *EC2) StopInstancesRequest(input *StopInstancesInput) (req *request.Requ // your Linux instance, Amazon EC2 charges a one-minute minimum for instance // usage, and thereafter charges per second for instance usage. // -// You can't start, stop, or hibernate Spot Instances, and you can't stop or -// hibernate instance store-backed instances. For information about using hibernation -// for Spot Instances, see Hibernating Interrupted Spot Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-interruptions.html#hibernate-spot-instances) -// in the Amazon Elastic Compute Cloud User Guide. +// You can't start or stop Spot Instances, and you can't stop instance store-backed +// instances. // -// When you stop or hibernate an instance, we shut it down. You can restart -// your instance at any time. Before stopping or hibernating an instance, make -// sure it is in a state from which it can be restarted. Stopping an instance -// does not preserve data stored in RAM, but hibernating an instance does preserve -// data stored in RAM. If an instance cannot hibernate successfully, a normal -// shutdown occurs. +// When you stop an instance, we shut it down. You can restart your instance +// at any time. Before stopping an instance, make sure it is in a state from +// which it can be restarted. Stopping an instance does not preserve data stored +// in RAM. // -// Stopping and hibernating an instance is different to rebooting or terminating -// it. For example, when you stop or hibernate an instance, the root device -// and any other devices attached to the instance persist. When you terminate -// an instance, the root device and any other devices attached during the instance -// launch are automatically deleted. For more information about the differences -// between rebooting, stopping, hibernating, and terminating instances, see -// Instance Lifecycle (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) +// Stopping an instance is different to rebooting or terminating it. For example, +// when you stop an instance, the root device and any other devices attached +// to the instance persist. When you terminate an instance, the root device +// and any other devices attached during the instance launch are automatically +// deleted. For more information about the differences between rebooting, stopping, +// and terminating instances, see Instance Lifecycle (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) // in the Amazon Elastic Compute Cloud User Guide. // // When you stop an instance, we attempt to shut it down forcibly after a short // while. If your instance appears stuck in the stopping state after a period // of time, there may be an issue with the underlying host computer. For more -// information, see Troubleshooting Stopping Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesStopping.html) +// information, see Troubleshooting Stopping Your Instance (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesStopping.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31525,88 +22466,12 @@ func (c *EC2) StopInstancesWithContext(ctx aws.Context, input *StopInstancesInpu return out, req.Send() } -const opTerminateClientVpnConnections = "TerminateClientVpnConnections" - -// TerminateClientVpnConnectionsRequest generates a "aws/request.Request" representing the -// client's request for the TerminateClientVpnConnections operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See TerminateClientVpnConnections for more information on using the TerminateClientVpnConnections -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the TerminateClientVpnConnectionsRequest method. -// req, resp := client.TerminateClientVpnConnectionsRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/TerminateClientVpnConnections -func (c *EC2) TerminateClientVpnConnectionsRequest(input *TerminateClientVpnConnectionsInput) (req *request.Request, output *TerminateClientVpnConnectionsOutput) { - op := &request.Operation{ - Name: opTerminateClientVpnConnections, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &TerminateClientVpnConnectionsInput{} - } - - output = &TerminateClientVpnConnectionsOutput{} - req = c.newRequest(op, input, output) - return -} - -// TerminateClientVpnConnections API operation for Amazon Elastic Compute Cloud. -// -// Terminates active Client VPN endpoint connections. This action can be used -// to terminate a specific client connection, or up to five connections established -// by a specific user. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation TerminateClientVpnConnections for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/TerminateClientVpnConnections -func (c *EC2) TerminateClientVpnConnections(input *TerminateClientVpnConnectionsInput) (*TerminateClientVpnConnectionsOutput, error) { - req, out := c.TerminateClientVpnConnectionsRequest(input) - return out, req.Send() -} - -// TerminateClientVpnConnectionsWithContext is the same as TerminateClientVpnConnections with the addition of -// the ability to pass a context and additional request options. -// -// See TerminateClientVpnConnections for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) TerminateClientVpnConnectionsWithContext(ctx aws.Context, input *TerminateClientVpnConnectionsInput, opts ...request.Option) (*TerminateClientVpnConnectionsOutput, error) { - req, out := c.TerminateClientVpnConnectionsRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - const opTerminateInstances = "TerminateInstances" // TerminateInstancesRequest generates a "aws/request.Request" representing the // client's request for the TerminateInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31645,8 +22510,8 @@ func (c *EC2) TerminateInstancesRequest(input *TerminateInstancesInput) (req *re // TerminateInstances API operation for Amazon Elastic Compute Cloud. // -// Shuts down the specified instances. This operation is idempotent; if you -// terminate an instance more than once, each call succeeds. +// Shuts down one or more instances. This operation is idempotent; if you terminate +// an instance more than once, each call succeeds. // // If you specify multiple instances and the request fails (for example, because // of a single incorrect instance ID), none of the instances are terminated. @@ -31664,11 +22529,11 @@ func (c *EC2) TerminateInstancesRequest(input *TerminateInstancesInput) (req *re // an instance, any attached EBS volumes with the DeleteOnTermination block // device mapping parameter set to true are automatically deleted. For more // information about the differences between stopping and terminating instances, -// see Instance Lifecycle (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) +// see Instance Lifecycle (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html) // in the Amazon Elastic Compute Cloud User Guide. // // For more information about troubleshooting, see Troubleshooting Terminating -// Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesShuttingDown.html) +// Your Instance (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesShuttingDown.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31704,7 +22569,7 @@ const opUnassignIpv6Addresses = "UnassignIpv6Addresses" // UnassignIpv6AddressesRequest generates a "aws/request.Request" representing the // client's request for the UnassignIpv6Addresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31778,7 +22643,7 @@ const opUnassignPrivateIpAddresses = "UnassignPrivateIpAddresses" // UnassignPrivateIpAddressesRequest generates a "aws/request.Request" representing the // client's request for the UnassignPrivateIpAddresses operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31812,7 +22677,8 @@ func (c *EC2) UnassignPrivateIpAddressesRequest(input *UnassignPrivateIpAddresse output = &UnassignPrivateIpAddressesOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(ec2query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + req.Handlers.Unmarshal.Remove(ec2query.UnmarshalHandler) + req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler) return } @@ -31853,7 +22719,7 @@ const opUnmonitorInstances = "UnmonitorInstances" // UnmonitorInstancesRequest generates a "aws/request.Request" representing the // client's request for the UnmonitorInstances operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31893,7 +22759,7 @@ func (c *EC2) UnmonitorInstancesRequest(input *UnmonitorInstancesInput) (req *re // UnmonitorInstances API operation for Amazon Elastic Compute Cloud. // // Disables detailed monitoring for a running instance. For more information, -// see Monitoring Your Instances and Volumes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-cloudwatch.html) +// see Monitoring Your Instances and Volumes (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-cloudwatch.html) // in the Amazon Elastic Compute Cloud User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -31929,7 +22795,7 @@ const opUpdateSecurityGroupRuleDescriptionsEgress = "UpdateSecurityGroupRuleDesc // UpdateSecurityGroupRuleDescriptionsEgressRequest generates a "aws/request.Request" representing the // client's request for the UpdateSecurityGroupRuleDescriptionsEgress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -31968,7 +22834,7 @@ func (c *EC2) UpdateSecurityGroupRuleDescriptionsEgressRequest(input *UpdateSecu // UpdateSecurityGroupRuleDescriptionsEgress API operation for Amazon Elastic Compute Cloud. // -// [VPC only] Updates the description of an egress (outbound) security group +// [EC2-VPC only] Updates the description of an egress (outbound) security group // rule. You can replace an existing description, or add a description to a // rule that did not have one previously. // @@ -32009,7 +22875,7 @@ const opUpdateSecurityGroupRuleDescriptionsIngress = "UpdateSecurityGroupRuleDes // UpdateSecurityGroupRuleDescriptionsIngressRequest generates a "aws/request.Request" representing the // client's request for the UpdateSecurityGroupRuleDescriptionsIngress operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -32084,87 +22950,6 @@ func (c *EC2) UpdateSecurityGroupRuleDescriptionsIngressWithContext(ctx aws.Cont return out, req.Send() } -const opWithdrawByoipCidr = "WithdrawByoipCidr" - -// WithdrawByoipCidrRequest generates a "aws/request.Request" representing the -// client's request for the WithdrawByoipCidr operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See WithdrawByoipCidr for more information on using the WithdrawByoipCidr -// API call, and error handling. -// -// This method is useful when you want to inject custom logic or configuration -// into the SDK's request lifecycle. Such as custom headers, or retry logic. -// -// -// // Example sending a request using the WithdrawByoipCidrRequest method. -// req, resp := client.WithdrawByoipCidrRequest(params) -// -// err := req.Send() -// if err == nil { // resp is now filled -// fmt.Println(resp) -// } -// -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/WithdrawByoipCidr -func (c *EC2) WithdrawByoipCidrRequest(input *WithdrawByoipCidrInput) (req *request.Request, output *WithdrawByoipCidrOutput) { - op := &request.Operation{ - Name: opWithdrawByoipCidr, - HTTPMethod: "POST", - HTTPPath: "/", - } - - if input == nil { - input = &WithdrawByoipCidrInput{} - } - - output = &WithdrawByoipCidrOutput{} - req = c.newRequest(op, input, output) - return -} - -// WithdrawByoipCidr API operation for Amazon Elastic Compute Cloud. -// -// Stops advertising an IPv4 address range that is provisioned as an address -// pool. -// -// You can perform this operation at most once every 10 seconds, even if you -// specify different address ranges each time. -// -// It can take a few minutes before traffic to the specified addresses stops -// routing to AWS because of BGP propagation delays. -// -// Returns awserr.Error for service API and SDK errors. Use runtime type assertions -// with awserr.Error's Code and Message methods to get detailed information about -// the error. -// -// See the AWS API reference guide for Amazon Elastic Compute Cloud's -// API operation WithdrawByoipCidr for usage and error information. -// See also, https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/WithdrawByoipCidr -func (c *EC2) WithdrawByoipCidr(input *WithdrawByoipCidrInput) (*WithdrawByoipCidrOutput, error) { - req, out := c.WithdrawByoipCidrRequest(input) - return out, req.Send() -} - -// WithdrawByoipCidrWithContext is the same as WithdrawByoipCidr with the addition of -// the ability to pass a context and additional request options. -// -// See WithdrawByoipCidr for details on how to use this API operation. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *EC2) WithdrawByoipCidrWithContext(ctx aws.Context, input *WithdrawByoipCidrInput, opts ...request.Option) (*WithdrawByoipCidrOutput, error) { - req, out := c.WithdrawByoipCidrRequest(input) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return out, req.Send() -} - // Contains the parameters for accepting the quote. type AcceptReservedInstancesExchangeQuoteInput struct { _ struct{} `type:"structure"` @@ -32261,79 +23046,6 @@ func (s *AcceptReservedInstancesExchangeQuoteOutput) SetExchangeId(v string) *Ac return s } -type AcceptTransitGatewayVpcAttachmentInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s AcceptTransitGatewayVpcAttachmentInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AcceptTransitGatewayVpcAttachmentInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *AcceptTransitGatewayVpcAttachmentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AcceptTransitGatewayVpcAttachmentInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *AcceptTransitGatewayVpcAttachmentInput) SetDryRun(v bool) *AcceptTransitGatewayVpcAttachmentInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *AcceptTransitGatewayVpcAttachmentInput) SetTransitGatewayAttachmentId(v string) *AcceptTransitGatewayVpcAttachmentInput { - s.TransitGatewayAttachmentId = &v - return s -} - -type AcceptTransitGatewayVpcAttachmentOutput struct { - _ struct{} `type:"structure"` - - // The VPC attachment. - TransitGatewayVpcAttachment *TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachment" type:"structure"` -} - -// String returns the string representation -func (s AcceptTransitGatewayVpcAttachmentOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AcceptTransitGatewayVpcAttachmentOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayVpcAttachment sets the TransitGatewayVpcAttachment field's value. -func (s *AcceptTransitGatewayVpcAttachmentOutput) SetTransitGatewayVpcAttachment(v *TransitGatewayVpcAttachment) *AcceptTransitGatewayVpcAttachmentOutput { - s.TransitGatewayVpcAttachment = v - return s -} - type AcceptVpcEndpointConnectionsInput struct { _ struct{} `type:"structure"` @@ -32421,6 +23133,7 @@ func (s *AcceptVpcEndpointConnectionsOutput) SetUnsuccessful(v []*UnsuccessfulIt return s } +// Contains the parameters for AcceptVpcPeeringConnection. type AcceptVpcPeeringConnectionInput struct { _ struct{} `type:"structure"` @@ -32457,6 +23170,7 @@ func (s *AcceptVpcPeeringConnectionInput) SetVpcPeeringConnectionId(v string) *A return s } +// Contains the output of AcceptVpcPeeringConnection. type AcceptVpcPeeringConnectionOutput struct { _ struct{} `type:"structure"` @@ -32487,7 +23201,7 @@ type AccountAttribute struct { // The name of the account attribute. AttributeName *string `locationName:"attributeName" type:"string"` - // The values for the account attribute. + // One or more values for the account attribute. AttributeValues []*AccountAttributeValue `locationName:"attributeValueSet" locationNameList:"item" type:"list"` } @@ -32620,9 +23334,6 @@ type Address struct { // The Elastic IP address. PublicIp *string `locationName:"publicIp" type:"string"` - // The ID of an address pool. - PublicIpv4Pool *string `locationName:"publicIpv4Pool" type:"string"` - // Any tags assigned to the Elastic IP address. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` } @@ -32685,97 +23396,17 @@ func (s *Address) SetPublicIp(v string) *Address { return s } -// SetPublicIpv4Pool sets the PublicIpv4Pool field's value. -func (s *Address) SetPublicIpv4Pool(v string) *Address { - s.PublicIpv4Pool = &v - return s -} - // SetTags sets the Tags field's value. func (s *Address) SetTags(v []*Tag) *Address { s.Tags = v return s } -type AdvertiseByoipCidrInput struct { - _ struct{} `type:"structure"` - - // The IPv4 address range, in CIDR notation. This must be the exact range that - // you provisioned. You can't advertise only a portion of the provisioned range. - // - // Cidr is a required field - Cidr *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s AdvertiseByoipCidrInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AdvertiseByoipCidrInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *AdvertiseByoipCidrInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AdvertiseByoipCidrInput"} - if s.Cidr == nil { - invalidParams.Add(request.NewErrParamRequired("Cidr")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCidr sets the Cidr field's value. -func (s *AdvertiseByoipCidrInput) SetCidr(v string) *AdvertiseByoipCidrInput { - s.Cidr = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *AdvertiseByoipCidrInput) SetDryRun(v bool) *AdvertiseByoipCidrInput { - s.DryRun = &v - return s -} - -type AdvertiseByoipCidrOutput struct { - _ struct{} `type:"structure"` - - // Information about the address range. - ByoipCidr *ByoipCidr `locationName:"byoipCidr" type:"structure"` -} - -// String returns the string representation -func (s AdvertiseByoipCidrOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AdvertiseByoipCidrOutput) GoString() string { - return s.String() -} - -// SetByoipCidr sets the ByoipCidr field's value. -func (s *AdvertiseByoipCidrOutput) SetByoipCidr(v *ByoipCidr) *AdvertiseByoipCidrOutput { - s.ByoipCidr = v - return s -} - +// Contains the parameters for AllocateAddress. type AllocateAddressInput struct { _ struct{} `type:"structure"` - // [EC2-VPC] The Elastic IP address to recover or an IPv4 address from an address - // pool. + // [EC2-VPC] The Elastic IP address to recover. Address *string `type:"string"` // Set to vpc to allocate the address for use with instances in a VPC. @@ -32788,11 +23419,6 @@ type AllocateAddressInput struct { // the required permissions, the error response is DryRunOperation. Otherwise, // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - - // The ID of an address pool that you own. Use this parameter to let Amazon - // EC2 select an address from the address pool. To specify a specific address - // from the address pool, use the Address parameter instead. - PublicIpv4Pool *string `type:"string"` } // String returns the string representation @@ -32823,12 +23449,7 @@ func (s *AllocateAddressInput) SetDryRun(v bool) *AllocateAddressInput { return s } -// SetPublicIpv4Pool sets the PublicIpv4Pool field's value. -func (s *AllocateAddressInput) SetPublicIpv4Pool(v string) *AllocateAddressInput { - s.PublicIpv4Pool = &v - return s -} - +// Contains the output of AllocateAddress. type AllocateAddressOutput struct { _ struct{} `type:"structure"` @@ -32842,9 +23463,6 @@ type AllocateAddressOutput struct { // The Elastic IP address. PublicIp *string `locationName:"publicIp" type:"string"` - - // The ID of an address pool. - PublicIpv4Pool *string `locationName:"publicIpv4Pool" type:"string"` } // String returns the string representation @@ -32875,44 +23493,30 @@ func (s *AllocateAddressOutput) SetPublicIp(v string) *AllocateAddressOutput { return s } -// SetPublicIpv4Pool sets the PublicIpv4Pool field's value. -func (s *AllocateAddressOutput) SetPublicIpv4Pool(v string) *AllocateAddressOutput { - s.PublicIpv4Pool = &v - return s -} - +// Contains the parameters for AllocateHosts. type AllocateHostsInput struct { _ struct{} `type:"structure"` - // Indicates whether the host accepts any untargeted instance launches that - // match its instance type configuration, or if it only accepts Host tenancy - // instance launches that specify its unique host ID. For more information, - // see Understanding Instance Placement and Host Affinity (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/how-dedicated-hosts-work.html#dedicated-hosts-understanding) - // in the Amazon EC2 User Guide for Linux Instances. + // This is enabled by default. This property allows instances to be automatically + // placed onto available Dedicated Hosts, when you are launching instances without + // specifying a host ID. // - // Default: on + // Default: Enabled AutoPlacement *string `locationName:"autoPlacement" type:"string" enum:"AutoPlacement"` - // The Availability Zone in which to allocate the Dedicated Host. + // The Availability Zone for the Dedicated Hosts. // // AvailabilityZone is a required field AvailabilityZone *string `locationName:"availabilityZone" type:"string" required:"true"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // in the Amazon Elastic Compute Cloud User Guide. ClientToken *string `locationName:"clientToken" type:"string"` - // Indicates whether to enable or disable host recovery for the Dedicated Host. - // Host recovery is disabled by default. For more information, see Host Recovery - // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-recovery.html) - // in the Amazon Elastic Compute Cloud User Guide. - // - // Default: off - HostRecovery *string `type:"string" enum:"HostRecovery"` - - // Specifies the instance type for which to configure your Dedicated Hosts. - // When you specify the instance type, that is the only instance type that you - // can launch onto that host. + // Specify the instance type for which to configure your Dedicated Hosts. When + // you specify the instance type, that is the only instance type that you can + // launch onto that host. // // InstanceType is a required field InstanceType *string `locationName:"instanceType" type:"string" required:"true"` @@ -32921,9 +23525,6 @@ type AllocateHostsInput struct { // // Quantity is a required field Quantity *int64 `locationName:"quantity" type:"integer" required:"true"` - - // The tags to apply to the Dedicated Host during creation. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` } // String returns the string representation @@ -32973,12 +23574,6 @@ func (s *AllocateHostsInput) SetClientToken(v string) *AllocateHostsInput { return s } -// SetHostRecovery sets the HostRecovery field's value. -func (s *AllocateHostsInput) SetHostRecovery(v string) *AllocateHostsInput { - s.HostRecovery = &v - return s -} - // SetInstanceType sets the InstanceType field's value. func (s *AllocateHostsInput) SetInstanceType(v string) *AllocateHostsInput { s.InstanceType = &v @@ -32991,12 +23586,6 @@ func (s *AllocateHostsInput) SetQuantity(v int64) *AllocateHostsInput { return s } -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *AllocateHostsInput) SetTagSpecifications(v []*TagSpecification) *AllocateHostsInput { - s.TagSpecifications = v - return s -} - // Contains the output of AllocateHosts. type AllocateHostsOutput struct { _ struct{} `type:"structure"` @@ -33055,108 +23644,6 @@ func (s *AllowedPrincipal) SetPrincipalType(v string) *AllowedPrincipal { return s } -type ApplySecurityGroupsToClientVpnTargetNetworkInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The IDs of the security groups to apply to the associated target network. - // Up to 5 security groups can be applied to an associated target network. - // - // SecurityGroupIds is a required field - SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"item" type:"list" required:"true"` - - // The ID of the VPC in which the associated target network is located. - // - // VpcId is a required field - VpcId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ApplySecurityGroupsToClientVpnTargetNetworkInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ApplySecurityGroupsToClientVpnTargetNetworkInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ApplySecurityGroupsToClientVpnTargetNetworkInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.SecurityGroupIds == nil { - invalidParams.Add(request.NewErrParamRequired("SecurityGroupIds")) - } - if s.VpcId == nil { - invalidParams.Add(request.NewErrParamRequired("VpcId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkInput) SetClientVpnEndpointId(v string) *ApplySecurityGroupsToClientVpnTargetNetworkInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkInput) SetDryRun(v bool) *ApplySecurityGroupsToClientVpnTargetNetworkInput { - s.DryRun = &v - return s -} - -// SetSecurityGroupIds sets the SecurityGroupIds field's value. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkInput) SetSecurityGroupIds(v []*string) *ApplySecurityGroupsToClientVpnTargetNetworkInput { - s.SecurityGroupIds = v - return s -} - -// SetVpcId sets the VpcId field's value. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkInput) SetVpcId(v string) *ApplySecurityGroupsToClientVpnTargetNetworkInput { - s.VpcId = &v - return s -} - -type ApplySecurityGroupsToClientVpnTargetNetworkOutput struct { - _ struct{} `type:"structure"` - - // The IDs of the applied security groups. - SecurityGroupIds []*string `locationName:"securityGroupIds" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s ApplySecurityGroupsToClientVpnTargetNetworkOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ApplySecurityGroupsToClientVpnTargetNetworkOutput) GoString() string { - return s.String() -} - -// SetSecurityGroupIds sets the SecurityGroupIds field's value. -func (s *ApplySecurityGroupsToClientVpnTargetNetworkOutput) SetSecurityGroupIds(v []*string) *ApplySecurityGroupsToClientVpnTargetNetworkOutput { - s.SecurityGroupIds = v - return s -} - type AssignIpv6AddressesInput struct { _ struct{} `type:"structure"` @@ -33323,12 +23810,6 @@ func (s *AssignPrivateIpAddressesInput) SetSecondaryPrivateIpAddressCount(v int6 type AssignPrivateIpAddressesOutput struct { _ struct{} `type:"structure"` - - // The private IP addresses assigned to the network interface. - AssignedPrivateIpAddresses []*AssignedPrivateIpAddress `locationName:"assignedPrivateIpAddressesSet" locationNameList:"item" type:"list"` - - // The ID of the network interface. - NetworkInterfaceId *string `locationName:"networkInterfaceId" type:"string"` } // String returns the string representation @@ -33341,42 +23822,7 @@ func (s AssignPrivateIpAddressesOutput) GoString() string { return s.String() } -// SetAssignedPrivateIpAddresses sets the AssignedPrivateIpAddresses field's value. -func (s *AssignPrivateIpAddressesOutput) SetAssignedPrivateIpAddresses(v []*AssignedPrivateIpAddress) *AssignPrivateIpAddressesOutput { - s.AssignedPrivateIpAddresses = v - return s -} - -// SetNetworkInterfaceId sets the NetworkInterfaceId field's value. -func (s *AssignPrivateIpAddressesOutput) SetNetworkInterfaceId(v string) *AssignPrivateIpAddressesOutput { - s.NetworkInterfaceId = &v - return s -} - -// Describes the private IP addresses assigned to a network interface. -type AssignedPrivateIpAddress struct { - _ struct{} `type:"structure"` - - // The private IP address assigned to the network interface. - PrivateIpAddress *string `locationName:"privateIpAddress" type:"string"` -} - -// String returns the string representation -func (s AssignedPrivateIpAddress) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssignedPrivateIpAddress) GoString() string { - return s.String() -} - -// SetPrivateIpAddress sets the PrivateIpAddress field's value. -func (s *AssignedPrivateIpAddress) SetPrivateIpAddress(v string) *AssignedPrivateIpAddress { - s.PrivateIpAddress = &v - return s -} - +// Contains the parameters for AssociateAddress. type AssociateAddressInput struct { _ struct{} `type:"structure"` @@ -33405,9 +23851,6 @@ type AssociateAddressInput struct { // [EC2-VPC] The ID of the network interface. If the instance has more than // one network interface, you must specify a network interface ID. - // - // For EC2-VPC, you can specify either the instance ID or the network interface - // ID, but not both. NetworkInterfaceId *string `locationName:"networkInterfaceId" type:"string"` // [EC2-VPC] The primary or secondary private IP address to associate with the @@ -33415,8 +23858,7 @@ type AssociateAddressInput struct { // address is associated with the primary private IP address. PrivateIpAddress *string `locationName:"privateIpAddress" type:"string"` - // The Elastic IP address to associate with the instance. This is required for - // EC2-Classic. + // The Elastic IP address. This is required for EC2-Classic. PublicIp *string `type:"string"` } @@ -33472,6 +23914,7 @@ func (s *AssociateAddressInput) SetPublicIp(v string) *AssociateAddressInput { return s } +// Contains the output of AssociateAddress. type AssociateAddressOutput struct { _ struct{} `type:"structure"` @@ -33496,112 +23939,7 @@ func (s *AssociateAddressOutput) SetAssociationId(v string) *AssociateAddressOut return s } -type AssociateClientVpnTargetNetworkInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the subnet to associate with the Client VPN endpoint. - // - // SubnetId is a required field - SubnetId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s AssociateClientVpnTargetNetworkInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociateClientVpnTargetNetworkInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *AssociateClientVpnTargetNetworkInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AssociateClientVpnTargetNetworkInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.SubnetId == nil { - invalidParams.Add(request.NewErrParamRequired("SubnetId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientToken sets the ClientToken field's value. -func (s *AssociateClientVpnTargetNetworkInput) SetClientToken(v string) *AssociateClientVpnTargetNetworkInput { - s.ClientToken = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *AssociateClientVpnTargetNetworkInput) SetClientVpnEndpointId(v string) *AssociateClientVpnTargetNetworkInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *AssociateClientVpnTargetNetworkInput) SetDryRun(v bool) *AssociateClientVpnTargetNetworkInput { - s.DryRun = &v - return s -} - -// SetSubnetId sets the SubnetId field's value. -func (s *AssociateClientVpnTargetNetworkInput) SetSubnetId(v string) *AssociateClientVpnTargetNetworkInput { - s.SubnetId = &v - return s -} - -type AssociateClientVpnTargetNetworkOutput struct { - _ struct{} `type:"structure"` - - // The unique ID of the target network association. - AssociationId *string `locationName:"associationId" type:"string"` - - // The current state of the target network association. - Status *AssociationStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s AssociateClientVpnTargetNetworkOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociateClientVpnTargetNetworkOutput) GoString() string { - return s.String() -} - -// SetAssociationId sets the AssociationId field's value. -func (s *AssociateClientVpnTargetNetworkOutput) SetAssociationId(v string) *AssociateClientVpnTargetNetworkOutput { - s.AssociationId = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *AssociateClientVpnTargetNetworkOutput) SetStatus(v *AssociationStatus) *AssociateClientVpnTargetNetworkOutput { - s.Status = v - return s -} - +// Contains the parameters for AssociateDhcpOptions. type AssociateDhcpOptionsInput struct { _ struct{} `type:"structure"` @@ -33756,6 +24094,7 @@ func (s *AssociateIamInstanceProfileOutput) SetIamInstanceProfileAssociation(v * return s } +// Contains the parameters for AssociateRouteTable. type AssociateRouteTableInput struct { _ struct{} `type:"structure"` @@ -33820,6 +24159,7 @@ func (s *AssociateRouteTableInput) SetSubnetId(v string) *AssociateRouteTableInp return s } +// Contains the output of AssociateRouteTable. type AssociateRouteTableOutput struct { _ struct{} `type:"structure"` @@ -33928,93 +24268,6 @@ func (s *AssociateSubnetCidrBlockOutput) SetSubnetId(v string) *AssociateSubnetC return s } -type AssociateTransitGatewayRouteTableInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s AssociateTransitGatewayRouteTableInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociateTransitGatewayRouteTableInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *AssociateTransitGatewayRouteTableInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AssociateTransitGatewayRouteTableInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *AssociateTransitGatewayRouteTableInput) SetDryRun(v bool) *AssociateTransitGatewayRouteTableInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *AssociateTransitGatewayRouteTableInput) SetTransitGatewayAttachmentId(v string) *AssociateTransitGatewayRouteTableInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *AssociateTransitGatewayRouteTableInput) SetTransitGatewayRouteTableId(v string) *AssociateTransitGatewayRouteTableInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type AssociateTransitGatewayRouteTableOutput struct { - _ struct{} `type:"structure"` - - // The ID of the association. - Association *TransitGatewayAssociation `locationName:"association" type:"structure"` -} - -// String returns the string representation -func (s AssociateTransitGatewayRouteTableOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociateTransitGatewayRouteTableOutput) GoString() string { - return s.String() -} - -// SetAssociation sets the Association field's value. -func (s *AssociateTransitGatewayRouteTableOutput) SetAssociation(v *TransitGatewayAssociation) *AssociateTransitGatewayRouteTableOutput { - s.Association = v - return s -} - type AssociateVpcCidrBlockInput struct { _ struct{} `type:"structure"` @@ -34114,73 +24367,7 @@ func (s *AssociateVpcCidrBlockOutput) SetVpcId(v string) *AssociateVpcCidrBlockO return s } -// Describes a target network that is associated with a Client VPN endpoint. -// A target network is a subnet in a VPC. -type AssociatedTargetNetwork struct { - _ struct{} `type:"structure"` - - // The ID of the subnet. - NetworkId *string `locationName:"networkId" type:"string"` - - // The target network type. - NetworkType *string `locationName:"networkType" type:"string" enum:"AssociatedNetworkType"` -} - -// String returns the string representation -func (s AssociatedTargetNetwork) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociatedTargetNetwork) GoString() string { - return s.String() -} - -// SetNetworkId sets the NetworkId field's value. -func (s *AssociatedTargetNetwork) SetNetworkId(v string) *AssociatedTargetNetwork { - s.NetworkId = &v - return s -} - -// SetNetworkType sets the NetworkType field's value. -func (s *AssociatedTargetNetwork) SetNetworkType(v string) *AssociatedTargetNetwork { - s.NetworkType = &v - return s -} - -// Describes the state of a target network association. -type AssociationStatus struct { - _ struct{} `type:"structure"` - - // The state of the target network association. - Code *string `locationName:"code" type:"string" enum:"AssociationStatusCode"` - - // A message about the status of the target network association, if applicable. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s AssociationStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AssociationStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *AssociationStatus) SetCode(v string) *AssociationStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *AssociationStatus) SetMessage(v string) *AssociationStatus { - s.Message = &v - return s -} - +// Contains the parameters for AttachClassicLinkVpc. type AttachClassicLinkVpcInput struct { _ struct{} `type:"structure"` @@ -34260,6 +24447,7 @@ func (s *AttachClassicLinkVpcInput) SetVpcId(v string) *AttachClassicLinkVpcInpu return s } +// Contains the output of AttachClassicLinkVpc. type AttachClassicLinkVpcOutput struct { _ struct{} `type:"structure"` @@ -34283,6 +24471,7 @@ func (s *AttachClassicLinkVpcOutput) SetReturn(v bool) *AttachClassicLinkVpcOutp return s } +// Contains the parameters for AttachInternetGateway. type AttachInternetGatewayInput struct { _ struct{} `type:"structure"` @@ -34681,203 +24870,7 @@ func (s *AttributeValue) SetValue(v string) *AttributeValue { return s } -// Information about an authorization rule. -type AuthorizationRule struct { - _ struct{} `type:"structure"` - - // Indicates whether the authorization rule grants access to all clients. - AccessAll *bool `locationName:"accessAll" type:"boolean"` - - // The ID of the Client VPN endpoint with which the authorization rule is associated. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // A brief description of the authorization rule. - Description *string `locationName:"description" type:"string"` - - // The IPv4 address range, in CIDR notation, of the network to which the authorization - // rule applies. - DestinationCidr *string `locationName:"destinationCidr" type:"string"` - - // The ID of the Active Directory group to which the authorization rule grants - // access. - GroupId *string `locationName:"groupId" type:"string"` - - // The current state of the authorization rule. - Status *ClientVpnAuthorizationRuleStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s AuthorizationRule) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AuthorizationRule) GoString() string { - return s.String() -} - -// SetAccessAll sets the AccessAll field's value. -func (s *AuthorizationRule) SetAccessAll(v bool) *AuthorizationRule { - s.AccessAll = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *AuthorizationRule) SetClientVpnEndpointId(v string) *AuthorizationRule { - s.ClientVpnEndpointId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *AuthorizationRule) SetDescription(v string) *AuthorizationRule { - s.Description = &v - return s -} - -// SetDestinationCidr sets the DestinationCidr field's value. -func (s *AuthorizationRule) SetDestinationCidr(v string) *AuthorizationRule { - s.DestinationCidr = &v - return s -} - -// SetGroupId sets the GroupId field's value. -func (s *AuthorizationRule) SetGroupId(v string) *AuthorizationRule { - s.GroupId = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *AuthorizationRule) SetStatus(v *ClientVpnAuthorizationRuleStatus) *AuthorizationRule { - s.Status = v - return s -} - -type AuthorizeClientVpnIngressInput struct { - _ struct{} `type:"structure"` - - // The ID of the Active Directory group to grant access. - AccessGroupId *string `type:"string"` - - // Indicates whether to grant access to all clients. Use true to grant all clients - // who successfully establish a VPN connection access to the network. - AuthorizeAllGroups *bool `type:"boolean"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // A brief description of the authorization rule. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The IPv4 address range, in CIDR notation, of the network for which access - // is being authorized. - // - // TargetNetworkCidr is a required field - TargetNetworkCidr *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s AuthorizeClientVpnIngressInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AuthorizeClientVpnIngressInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *AuthorizeClientVpnIngressInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AuthorizeClientVpnIngressInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.TargetNetworkCidr == nil { - invalidParams.Add(request.NewErrParamRequired("TargetNetworkCidr")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAccessGroupId sets the AccessGroupId field's value. -func (s *AuthorizeClientVpnIngressInput) SetAccessGroupId(v string) *AuthorizeClientVpnIngressInput { - s.AccessGroupId = &v - return s -} - -// SetAuthorizeAllGroups sets the AuthorizeAllGroups field's value. -func (s *AuthorizeClientVpnIngressInput) SetAuthorizeAllGroups(v bool) *AuthorizeClientVpnIngressInput { - s.AuthorizeAllGroups = &v - return s -} - -// SetClientToken sets the ClientToken field's value. -func (s *AuthorizeClientVpnIngressInput) SetClientToken(v string) *AuthorizeClientVpnIngressInput { - s.ClientToken = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *AuthorizeClientVpnIngressInput) SetClientVpnEndpointId(v string) *AuthorizeClientVpnIngressInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *AuthorizeClientVpnIngressInput) SetDescription(v string) *AuthorizeClientVpnIngressInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *AuthorizeClientVpnIngressInput) SetDryRun(v bool) *AuthorizeClientVpnIngressInput { - s.DryRun = &v - return s -} - -// SetTargetNetworkCidr sets the TargetNetworkCidr field's value. -func (s *AuthorizeClientVpnIngressInput) SetTargetNetworkCidr(v string) *AuthorizeClientVpnIngressInput { - s.TargetNetworkCidr = &v - return s -} - -type AuthorizeClientVpnIngressOutput struct { - _ struct{} `type:"structure"` - - // The current state of the authorization rule. - Status *ClientVpnAuthorizationRuleStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s AuthorizeClientVpnIngressOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s AuthorizeClientVpnIngressOutput) GoString() string { - return s.String() -} - -// SetStatus sets the Status field's value. -func (s *AuthorizeClientVpnIngressOutput) SetStatus(v *ClientVpnAuthorizationRuleStatus) *AuthorizeClientVpnIngressOutput { - s.Status = v - return s -} - +// Contains the parameters for AuthorizeSecurityGroupEgress. type AuthorizeSecurityGroupEgressInput struct { _ struct{} `type:"structure"` @@ -34898,8 +24891,8 @@ type AuthorizeSecurityGroupEgressInput struct { // GroupId is a required field GroupId *string `locationName:"groupId" type:"string" required:"true"` - // The sets of IP permissions. You can't specify a destination security group - // and a CIDR IP address range in the same set of permissions. + // One or more sets of IP permissions. You can't specify a destination security + // group and a CIDR IP address range in the same set of permissions. IpPermissions []*IpPermission `locationName:"ipPermissions" locationNameList:"item" type:"list"` // Not supported. Use a set of IP permissions to specify the protocol name or @@ -35009,15 +25002,12 @@ func (s AuthorizeSecurityGroupEgressOutput) GoString() string { return s.String() } +// Contains the parameters for AuthorizeSecurityGroupIngress. type AuthorizeSecurityGroupIngressInput struct { _ struct{} `type:"structure"` - // The IPv4 address range, in CIDR format. You can't specify this parameter - // when specifying a source security group. To specify an IPv6 address range, - // use a set of IP permissions. - // - // Alternatively, use a set of IP permissions to specify multiple rules and - // a description for the rule. + // The CIDR IPv4 address range. You can't specify this parameter when specifying + // a source security group. CidrIp *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -35026,12 +25016,9 @@ type AuthorizeSecurityGroupIngressInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The start of port range for the TCP and UDP protocols, or an ICMP type number. - // For the ICMP type number, use -1 to specify all types. If you specify all - // ICMP types, you must specify all codes. - // - // Alternatively, use a set of IP permissions to specify multiple rules and - // a description for the rule. + // The start of port range for the TCP and UDP protocols, or an ICMP/ICMPv6 + // type number. For the ICMP/ICMPv6 type number, use -1 to specify all types. + // If you specify all ICMP/ICMPv6 types, you must specify all codes. FromPort *int64 `type:"integer"` // The ID of the security group. You must specify either the security group @@ -35043,18 +25030,16 @@ type AuthorizeSecurityGroupIngressInput struct { // either the security group ID or the security group name in the request. GroupName *string `type:"string"` - // The sets of IP permissions. + // One or more sets of IP permissions. Can be used to specify multiple rules + // in a single command. IpPermissions []*IpPermission `locationNameList:"item" type:"list"` // The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml)). - // To specify icmpv6, use a set of IP permissions. - // - // [VPC only] Use -1 to specify all protocols. If you specify -1 or a protocol - // other than tcp, udp, or icmp, traffic on all ports is allowed, regardless - // of any ports you specify. - // - // Alternatively, use a set of IP permissions to specify multiple rules and - // a description for the rule. + // (VPC only) Use -1 to specify all protocols. If you specify -1, or a protocol + // number other than tcp, udp, icmp, or 58 (ICMPv6), traffic on all ports is + // allowed, regardless of any ports you specify. For tcp, udp, and icmp, you + // must specify a port range. For protocol 58 (ICMPv6), you can optionally specify + // a port range; if you don't, traffic for all types and codes is allowed. IpProtocol *string `type:"string"` // [EC2-Classic, default VPC] The name of the source security group. You can't @@ -35066,20 +25051,17 @@ type AuthorizeSecurityGroupIngressInput struct { // be in the same VPC. SourceSecurityGroupName *string `type:"string"` - // [nondefault VPC] The AWS account ID for the source security group, if the - // source security group is in a different account. You can't specify this parameter + // [EC2-Classic] The AWS account ID for the source security group, if the source + // security group is in a different account. You can't specify this parameter // in combination with the following parameters: the CIDR IP address range, // the IP protocol, the start of the port range, and the end of the port range. // Creates rules that grant full ICMP, UDP, and TCP access. To create a rule // with a specific IP protocol and port range, use a set of IP permissions instead. SourceSecurityGroupOwnerId *string `type:"string"` - // The end of port range for the TCP and UDP protocols, or an ICMP code number. - // For the ICMP code number, use -1 to specify all codes. If you specify all - // ICMP types, you must specify all codes. - // - // Alternatively, use a set of IP permissions to specify multiple rules and - // a description for the rule. + // The end of port range for the TCP and UDP protocols, or an ICMP/ICMPv6 code + // number. For the ICMP/ICMPv6 code number, use -1 to specify all codes. If + // you specify all ICMP/ICMPv6 types, you must specify all codes. ToPort *int64 `type:"integer"` } @@ -35174,15 +25156,12 @@ type AvailabilityZone struct { // Any messages about the Availability Zone. Messages []*AvailabilityZoneMessage `locationName:"messageSet" locationNameList:"item" type:"list"` - // The name of the Region. + // The name of the region. RegionName *string `locationName:"regionName" type:"string"` // The state of the Availability Zone. State *string `locationName:"zoneState" type:"string" enum:"AvailabilityZoneState"` - // The ID of the Availability Zone. - ZoneId *string `locationName:"zoneId" type:"string"` - // The name of the Availability Zone. ZoneName *string `locationName:"zoneName" type:"string"` } @@ -35215,12 +25194,6 @@ func (s *AvailabilityZone) SetState(v string) *AvailabilityZone { return s } -// SetZoneId sets the ZoneId field's value. -func (s *AvailabilityZone) SetZoneId(v string) *AvailabilityZone { - s.ZoneId = &v - return s -} - // SetZoneName sets the ZoneName field's value. func (s *AvailabilityZone) SetZoneName(v string) *AvailabilityZone { s.ZoneName = &v @@ -35589,59 +25562,6 @@ func (s *BundleTaskError) SetMessage(v string) *BundleTaskError { return s } -// Information about an address range that is provisioned for use with your -// AWS resources through bring your own IP addresses (BYOIP). -type ByoipCidr struct { - _ struct{} `type:"structure"` - - // The public IPv4 address range, in CIDR notation. - Cidr *string `locationName:"cidr" type:"string"` - - // The description of the address range. - Description *string `locationName:"description" type:"string"` - - // The state of the address pool. - State *string `locationName:"state" type:"string" enum:"ByoipCidrState"` - - // Upon success, contains the ID of the address pool. Otherwise, contains an - // error message. - StatusMessage *string `locationName:"statusMessage" type:"string"` -} - -// String returns the string representation -func (s ByoipCidr) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ByoipCidr) GoString() string { - return s.String() -} - -// SetCidr sets the Cidr field's value. -func (s *ByoipCidr) SetCidr(v string) *ByoipCidr { - s.Cidr = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *ByoipCidr) SetDescription(v string) *ByoipCidr { - s.Description = &v - return s -} - -// SetState sets the State field's value. -func (s *ByoipCidr) SetState(v string) *ByoipCidr { - s.State = &v - return s -} - -// SetStatusMessage sets the StatusMessage field's value. -func (s *ByoipCidr) SetStatusMessage(v string) *ByoipCidr { - s.StatusMessage = &v - return s -} - // Contains the parameters for CancelBundleTask. type CancelBundleTaskInput struct { _ struct{} `type:"structure"` @@ -35717,79 +25637,7 @@ func (s *CancelBundleTaskOutput) SetBundleTask(v *BundleTask) *CancelBundleTaskO return s } -type CancelCapacityReservationInput struct { - _ struct{} `type:"structure"` - - // The ID of the Capacity Reservation to be cancelled. - // - // CapacityReservationId is a required field - CapacityReservationId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s CancelCapacityReservationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CancelCapacityReservationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CancelCapacityReservationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CancelCapacityReservationInput"} - if s.CapacityReservationId == nil { - invalidParams.Add(request.NewErrParamRequired("CapacityReservationId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *CancelCapacityReservationInput) SetCapacityReservationId(v string) *CancelCapacityReservationInput { - s.CapacityReservationId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CancelCapacityReservationInput) SetDryRun(v bool) *CancelCapacityReservationInput { - s.DryRun = &v - return s -} - -type CancelCapacityReservationOutput struct { - _ struct{} `type:"structure"` - - // Returns true if the request succeeds; otherwise, it returns an error. - Return *bool `locationName:"return" type:"boolean"` -} - -// String returns the string representation -func (s CancelCapacityReservationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CancelCapacityReservationOutput) GoString() string { - return s.String() -} - -// SetReturn sets the Return field's value. -func (s *CancelCapacityReservationOutput) SetReturn(v bool) *CancelCapacityReservationOutput { - s.Return = &v - return s -} - +// Contains the parameters for CancelConversionTask. type CancelConversionTaskInput struct { _ struct{} `type:"structure"` @@ -35863,6 +25711,7 @@ func (s CancelConversionTaskOutput) GoString() string { return s.String() } +// Contains the parameters for CancelExportTask. type CancelExportTaskInput struct { _ struct{} `type:"structure"` @@ -35915,6 +25764,7 @@ func (s CancelExportTaskOutput) GoString() string { return s.String() } +// Contains the parameters for CancelImportTask. type CancelImportTaskInput struct { _ struct{} `type:"structure"` @@ -35959,6 +25809,7 @@ func (s *CancelImportTaskInput) SetImportTaskId(v string) *CancelImportTaskInput return s } +// Contains the output for CancelImportTask. type CancelImportTaskOutput struct { _ struct{} `type:"structure"` @@ -36068,10 +25919,14 @@ type CancelSpotFleetRequestsError struct { _ struct{} `type:"structure"` // The error code. - Code *string `locationName:"code" type:"string" enum:"CancelBatchErrorCode"` + // + // Code is a required field + Code *string `locationName:"code" type:"string" required:"true" enum:"CancelBatchErrorCode"` // The description for the error code. - Message *string `locationName:"message" type:"string"` + // + // Message is a required field + Message *string `locationName:"message" type:"string" required:"true"` } // String returns the string representation @@ -36101,10 +25956,14 @@ type CancelSpotFleetRequestsErrorItem struct { _ struct{} `type:"structure"` // The error. - Error *CancelSpotFleetRequestsError `locationName:"error" type:"structure"` + // + // Error is a required field + Error *CancelSpotFleetRequestsError `locationName:"error" type:"structure" required:"true"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` } // String returns the string representation @@ -36233,13 +26092,19 @@ type CancelSpotFleetRequestsSuccessItem struct { _ struct{} `type:"structure"` // The current state of the Spot Fleet request. - CurrentSpotFleetRequestState *string `locationName:"currentSpotFleetRequestState" type:"string" enum:"BatchState"` + // + // CurrentSpotFleetRequestState is a required field + CurrentSpotFleetRequestState *string `locationName:"currentSpotFleetRequestState" type:"string" required:"true" enum:"BatchState"` // The previous state of the Spot Fleet request. - PreviousSpotFleetRequestState *string `locationName:"previousSpotFleetRequestState" type:"string" enum:"BatchState"` + // + // PreviousSpotFleetRequestState is a required field + PreviousSpotFleetRequestState *string `locationName:"previousSpotFleetRequestState" type:"string" required:"true" enum:"BatchState"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` } // String returns the string representation @@ -36378,456 +26243,6 @@ func (s *CancelledSpotInstanceRequest) SetState(v string) *CancelledSpotInstance return s } -// Describes a Capacity Reservation. -type CapacityReservation struct { - _ struct{} `type:"structure"` - - // The Availability Zone in which the capacity is reserved. - AvailabilityZone *string `locationName:"availabilityZone" type:"string"` - - // The remaining capacity. Indicates the number of instances that can be launched - // in the Capacity Reservation. - AvailableInstanceCount *int64 `locationName:"availableInstanceCount" type:"integer"` - - // The ID of the Capacity Reservation. - CapacityReservationId *string `locationName:"capacityReservationId" type:"string"` - - // The date and time at which the Capacity Reservation was created. - CreateDate *time.Time `locationName:"createDate" type:"timestamp"` - - // Indicates whether the Capacity Reservation supports EBS-optimized instances. - // This optimization provides dedicated throughput to Amazon EBS and an optimized - // configuration stack to provide optimal I/O performance. This optimization - // isn't available with all instance types. Additional usage charges apply when - // using an EBS- optimized instance. - EbsOptimized *bool `locationName:"ebsOptimized" type:"boolean"` - - // The date and time at which the Capacity Reservation expires. When a Capacity - // Reservation expires, the reserved capacity is released and you can no longer - // launch instances into it. The Capacity Reservation's state changes to expired - // when it reaches its end date and time. - EndDate *time.Time `locationName:"endDate" type:"timestamp"` - - // Indicates the way in which the Capacity Reservation ends. A Capacity Reservation - // can have one of the following end types: - // - // * unlimited - The Capacity Reservation remains active until you explicitly - // cancel it. - // - // * limited - The Capacity Reservation expires automatically at a specified - // date and time. - EndDateType *string `locationName:"endDateType" type:"string" enum:"EndDateType"` - - // Indicates whether the Capacity Reservation supports instances with temporary, - // block-level storage. - EphemeralStorage *bool `locationName:"ephemeralStorage" type:"boolean"` - - // Indicates the type of instance launches that the Capacity Reservation accepts. - // The options include: - // - // * open - The Capacity Reservation accepts all instances that have matching - // attributes (instance type, platform, and Availability Zone). Instances - // that have matching attributes launch into the Capacity Reservation automatically - // without specifying any additional parameters. - // - // * targeted - The Capacity Reservation only accepts instances that have - // matching attributes (instance type, platform, and Availability Zone), - // and explicitly target the Capacity Reservation. This ensures that only - // permitted instances can use the reserved capacity. - InstanceMatchCriteria *string `locationName:"instanceMatchCriteria" type:"string" enum:"InstanceMatchCriteria"` - - // The type of operating system for which the Capacity Reservation reserves - // capacity. - InstancePlatform *string `locationName:"instancePlatform" type:"string" enum:"CapacityReservationInstancePlatform"` - - // The type of instance for which the Capacity Reservation reserves capacity. - InstanceType *string `locationName:"instanceType" type:"string"` - - // The current state of the Capacity Reservation. A Capacity Reservation can - // be in one of the following states: - // - // * active - The Capacity Reservation is active and the capacity is available - // for your use. - // - // * cancelled - The Capacity Reservation expired automatically at the date - // and time specified in your request. The reserved capacity is no longer - // available for your use. - // - // * expired - The Capacity Reservation was manually cancelled. The reserved - // capacity is no longer available for your use. - // - // * pending - The Capacity Reservation request was successful but the capacity - // provisioning is still pending. - // - // * failed - The Capacity Reservation request has failed. A request might - // fail due to invalid request parameters, capacity constraints, or instance - // limit constraints. Failed requests are retained for 60 minutes. - State *string `locationName:"state" type:"string" enum:"CapacityReservationState"` - - // Any tags assigned to the Capacity Reservation. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // Indicates the tenancy of the Capacity Reservation. A Capacity Reservation - // can have one of the following tenancy settings: - // - // * default - The Capacity Reservation is created on hardware that is shared - // with other AWS accounts. - // - // * dedicated - The Capacity Reservation is created on single-tenant hardware - // that is dedicated to a single AWS account. - Tenancy *string `locationName:"tenancy" type:"string" enum:"CapacityReservationTenancy"` - - // The number of instances for which the Capacity Reservation reserves capacity. - TotalInstanceCount *int64 `locationName:"totalInstanceCount" type:"integer"` -} - -// String returns the string representation -func (s CapacityReservation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CapacityReservation) GoString() string { - return s.String() -} - -// SetAvailabilityZone sets the AvailabilityZone field's value. -func (s *CapacityReservation) SetAvailabilityZone(v string) *CapacityReservation { - s.AvailabilityZone = &v - return s -} - -// SetAvailableInstanceCount sets the AvailableInstanceCount field's value. -func (s *CapacityReservation) SetAvailableInstanceCount(v int64) *CapacityReservation { - s.AvailableInstanceCount = &v - return s -} - -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *CapacityReservation) SetCapacityReservationId(v string) *CapacityReservation { - s.CapacityReservationId = &v - return s -} - -// SetCreateDate sets the CreateDate field's value. -func (s *CapacityReservation) SetCreateDate(v time.Time) *CapacityReservation { - s.CreateDate = &v - return s -} - -// SetEbsOptimized sets the EbsOptimized field's value. -func (s *CapacityReservation) SetEbsOptimized(v bool) *CapacityReservation { - s.EbsOptimized = &v - return s -} - -// SetEndDate sets the EndDate field's value. -func (s *CapacityReservation) SetEndDate(v time.Time) *CapacityReservation { - s.EndDate = &v - return s -} - -// SetEndDateType sets the EndDateType field's value. -func (s *CapacityReservation) SetEndDateType(v string) *CapacityReservation { - s.EndDateType = &v - return s -} - -// SetEphemeralStorage sets the EphemeralStorage field's value. -func (s *CapacityReservation) SetEphemeralStorage(v bool) *CapacityReservation { - s.EphemeralStorage = &v - return s -} - -// SetInstanceMatchCriteria sets the InstanceMatchCriteria field's value. -func (s *CapacityReservation) SetInstanceMatchCriteria(v string) *CapacityReservation { - s.InstanceMatchCriteria = &v - return s -} - -// SetInstancePlatform sets the InstancePlatform field's value. -func (s *CapacityReservation) SetInstancePlatform(v string) *CapacityReservation { - s.InstancePlatform = &v - return s -} - -// SetInstanceType sets the InstanceType field's value. -func (s *CapacityReservation) SetInstanceType(v string) *CapacityReservation { - s.InstanceType = &v - return s -} - -// SetState sets the State field's value. -func (s *CapacityReservation) SetState(v string) *CapacityReservation { - s.State = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *CapacityReservation) SetTags(v []*Tag) *CapacityReservation { - s.Tags = v - return s -} - -// SetTenancy sets the Tenancy field's value. -func (s *CapacityReservation) SetTenancy(v string) *CapacityReservation { - s.Tenancy = &v - return s -} - -// SetTotalInstanceCount sets the TotalInstanceCount field's value. -func (s *CapacityReservation) SetTotalInstanceCount(v int64) *CapacityReservation { - s.TotalInstanceCount = &v - return s -} - -// Describes an instance's Capacity Reservation targeting option. You can specify -// only one parameter at a time. If you specify CapacityReservationPreference -// and CapacityReservationTarget, the request fails. -// -// Use the CapacityReservationPreference parameter to configure the instance -// to run as an On-Demand Instance or to run in any open Capacity Reservation -// that has matching attributes (instance type, platform, Availability Zone). -// Use the CapacityReservationTarget parameter to explicitly target a specific -// Capacity Reservation. -type CapacityReservationSpecification struct { - _ struct{} `type:"structure"` - - // Indicates the instance's Capacity Reservation preferences. Possible preferences - // include: - // - // * open - The instance can run in any open Capacity Reservation that has - // matching attributes (instance type, platform, Availability Zone). - // - // * none - The instance avoids running in a Capacity Reservation even if - // one is available. The instance runs as an On-Demand Instance. - CapacityReservationPreference *string `type:"string" enum:"CapacityReservationPreference"` - - // Information about the target Capacity Reservation. - CapacityReservationTarget *CapacityReservationTarget `type:"structure"` -} - -// String returns the string representation -func (s CapacityReservationSpecification) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CapacityReservationSpecification) GoString() string { - return s.String() -} - -// SetCapacityReservationPreference sets the CapacityReservationPreference field's value. -func (s *CapacityReservationSpecification) SetCapacityReservationPreference(v string) *CapacityReservationSpecification { - s.CapacityReservationPreference = &v - return s -} - -// SetCapacityReservationTarget sets the CapacityReservationTarget field's value. -func (s *CapacityReservationSpecification) SetCapacityReservationTarget(v *CapacityReservationTarget) *CapacityReservationSpecification { - s.CapacityReservationTarget = v - return s -} - -// Describes the instance's Capacity Reservation targeting preferences. The -// action returns the capacityReservationPreference response element if the -// instance is configured to run in On-Demand capacity, or if it is configured -// in run in any open Capacity Reservation that has matching attributes (instance -// type, platform, Availability Zone). The action returns the capacityReservationTarget -// response element if the instance explicily targets a specific Capacity Reservation. -type CapacityReservationSpecificationResponse struct { - _ struct{} `type:"structure"` - - // Describes the instance's Capacity Reservation preferences. Possible preferences - // include: - // - // * open - The instance can run in any open Capacity Reservation that has - // matching attributes (instance type, platform, Availability Zone). - // - // * none - The instance avoids running in a Capacity Reservation even if - // one is available. The instance runs in On-Demand capacity. - CapacityReservationPreference *string `locationName:"capacityReservationPreference" type:"string" enum:"CapacityReservationPreference"` - - // Information about the targeted Capacity Reservation. - CapacityReservationTarget *CapacityReservationTargetResponse `locationName:"capacityReservationTarget" type:"structure"` -} - -// String returns the string representation -func (s CapacityReservationSpecificationResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CapacityReservationSpecificationResponse) GoString() string { - return s.String() -} - -// SetCapacityReservationPreference sets the CapacityReservationPreference field's value. -func (s *CapacityReservationSpecificationResponse) SetCapacityReservationPreference(v string) *CapacityReservationSpecificationResponse { - s.CapacityReservationPreference = &v - return s -} - -// SetCapacityReservationTarget sets the CapacityReservationTarget field's value. -func (s *CapacityReservationSpecificationResponse) SetCapacityReservationTarget(v *CapacityReservationTargetResponse) *CapacityReservationSpecificationResponse { - s.CapacityReservationTarget = v - return s -} - -// Describes a target Capacity Reservation. -type CapacityReservationTarget struct { - _ struct{} `type:"structure"` - - // The ID of the Capacity Reservation. - CapacityReservationId *string `type:"string"` -} - -// String returns the string representation -func (s CapacityReservationTarget) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CapacityReservationTarget) GoString() string { - return s.String() -} - -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *CapacityReservationTarget) SetCapacityReservationId(v string) *CapacityReservationTarget { - s.CapacityReservationId = &v - return s -} - -// Describes a target Capacity Reservation. -type CapacityReservationTargetResponse struct { - _ struct{} `type:"structure"` - - // The ID of the Capacity Reservation. - CapacityReservationId *string `locationName:"capacityReservationId" type:"string"` -} - -// String returns the string representation -func (s CapacityReservationTargetResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CapacityReservationTargetResponse) GoString() string { - return s.String() -} - -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *CapacityReservationTargetResponse) SetCapacityReservationId(v string) *CapacityReservationTargetResponse { - s.CapacityReservationId = &v - return s -} - -// Information about the client certificate used for authentication. -type CertificateAuthentication struct { - _ struct{} `type:"structure"` - - // The ARN of the client certificate. - ClientRootCertificateChain *string `locationName:"clientRootCertificateChain" type:"string"` -} - -// String returns the string representation -func (s CertificateAuthentication) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CertificateAuthentication) GoString() string { - return s.String() -} - -// SetClientRootCertificateChain sets the ClientRootCertificateChain field's value. -func (s *CertificateAuthentication) SetClientRootCertificateChain(v string) *CertificateAuthentication { - s.ClientRootCertificateChain = &v - return s -} - -// Information about the client certificate to be used for authentication. -type CertificateAuthenticationRequest struct { - _ struct{} `type:"structure"` - - // The ARN of the client certificate. The certificate must be signed by a certificate - // authority (CA) and it must be provisioned in AWS Certificate Manager (ACM). - ClientRootCertificateChainArn *string `type:"string"` -} - -// String returns the string representation -func (s CertificateAuthenticationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CertificateAuthenticationRequest) GoString() string { - return s.String() -} - -// SetClientRootCertificateChainArn sets the ClientRootCertificateChainArn field's value. -func (s *CertificateAuthenticationRequest) SetClientRootCertificateChainArn(v string) *CertificateAuthenticationRequest { - s.ClientRootCertificateChainArn = &v - return s -} - -// Provides authorization for Amazon to bring a specific IP address range to -// a specific AWS account using bring your own IP addresses (BYOIP). For more -// information, see Prepare to Bring Your Address Range to Your AWS Account -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-byoip.html#prepare-for-byoip) -// in the Amazon Elastic Compute Cloud User Guide. -type CidrAuthorizationContext struct { - _ struct{} `type:"structure"` - - // The plain-text authorization message for the prefix and account. - // - // Message is a required field - Message *string `type:"string" required:"true"` - - // The signed authorization message for the prefix and account. - // - // Signature is a required field - Signature *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CidrAuthorizationContext) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CidrAuthorizationContext) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CidrAuthorizationContext) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CidrAuthorizationContext"} - if s.Message == nil { - invalidParams.Add(request.NewErrParamRequired("Message")) - } - if s.Signature == nil { - invalidParams.Add(request.NewErrParamRequired("Signature")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetMessage sets the Message field's value. -func (s *CidrAuthorizationContext) SetMessage(v string) *CidrAuthorizationContext { - s.Message = &v - return s -} - -// SetSignature sets the Signature field's value. -func (s *CidrAuthorizationContext) SetSignature(v string) *CidrAuthorizationContext { - s.Signature = &v - return s -} - // Describes an IPv4 CIDR block. type CidrBlock struct { _ struct{} `type:"structure"` @@ -36941,7 +26356,9 @@ type ClassicLoadBalancer struct { _ struct{} `type:"structure"` // The name of the load balancer. - Name *string `locationName:"name" type:"string"` + // + // Name is a required field + Name *string `locationName:"name" type:"string" required:"true"` } // String returns the string representation @@ -36954,6 +26371,19 @@ func (s ClassicLoadBalancer) GoString() string { return s.String() } +// Validate inspects the fields of the type to determine if they are valid. +func (s *ClassicLoadBalancer) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ClassicLoadBalancer"} + if s.Name == nil { + invalidParams.Add(request.NewErrParamRequired("Name")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + // SetName sets the Name field's value. func (s *ClassicLoadBalancer) SetName(v string) *ClassicLoadBalancer { s.Name = &v @@ -36966,7 +26396,9 @@ type ClassicLoadBalancersConfig struct { _ struct{} `type:"structure"` // One or more Classic Load Balancers. - ClassicLoadBalancers []*ClassicLoadBalancer `locationName:"classicLoadBalancers" locationNameList:"item" min:"1" type:"list"` + // + // ClassicLoadBalancers is a required field + ClassicLoadBalancers []*ClassicLoadBalancer `locationName:"classicLoadBalancers" locationNameList:"item" min:"1" type:"list" required:"true"` } // String returns the string representation @@ -36982,9 +26414,22 @@ func (s ClassicLoadBalancersConfig) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *ClassicLoadBalancersConfig) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ClassicLoadBalancersConfig"} + if s.ClassicLoadBalancers == nil { + invalidParams.Add(request.NewErrParamRequired("ClassicLoadBalancers")) + } if s.ClassicLoadBalancers != nil && len(s.ClassicLoadBalancers) < 1 { invalidParams.Add(request.NewErrParamMinLen("ClassicLoadBalancers", 1)) } + if s.ClassicLoadBalancers != nil { + for i, v := range s.ClassicLoadBalancers { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ClassicLoadBalancers", i), err.(request.ErrInvalidParams)) + } + } + } if invalidParams.Len() > 0 { return invalidParams @@ -36998,40 +26443,6 @@ func (s *ClassicLoadBalancersConfig) SetClassicLoadBalancers(v []*ClassicLoadBal return s } -// Describes the state of a client certificate revocation list. -type ClientCertificateRevocationListStatus struct { - _ struct{} `type:"structure"` - - // The state of the client certificate revocation list. - Code *string `locationName:"code" type:"string" enum:"ClientCertificateRevocationListStatusCode"` - - // A message about the status of the client certificate revocation list, if - // applicable. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s ClientCertificateRevocationListStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientCertificateRevocationListStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *ClientCertificateRevocationListStatus) SetCode(v string) *ClientCertificateRevocationListStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *ClientCertificateRevocationListStatus) SetMessage(v string) *ClientCertificateRevocationListStatus { - s.Message = &v - return s -} - // Describes the client-specific data. type ClientData struct { _ struct{} `type:"structure"` @@ -37083,624 +26494,7 @@ func (s *ClientData) SetUploadStart(v time.Time) *ClientData { return s } -// Describes the authentication methods used by a Client VPN endpoint. Client -// VPN supports Active Directory and mutual authentication. For more information, -// see Authentication (https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/authentication-authrization.html#client-authentication) -// in the AWS Client VPN Administrator Guide. -type ClientVpnAuthentication struct { - _ struct{} `type:"structure"` - - // Information about the Active Directory, if applicable. - ActiveDirectory *DirectoryServiceAuthentication `locationName:"activeDirectory" type:"structure"` - - // Information about the authentication certificates, if applicable. - MutualAuthentication *CertificateAuthentication `locationName:"mutualAuthentication" type:"structure"` - - // The authentication type used. - Type *string `locationName:"type" type:"string" enum:"ClientVpnAuthenticationType"` -} - -// String returns the string representation -func (s ClientVpnAuthentication) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnAuthentication) GoString() string { - return s.String() -} - -// SetActiveDirectory sets the ActiveDirectory field's value. -func (s *ClientVpnAuthentication) SetActiveDirectory(v *DirectoryServiceAuthentication) *ClientVpnAuthentication { - s.ActiveDirectory = v - return s -} - -// SetMutualAuthentication sets the MutualAuthentication field's value. -func (s *ClientVpnAuthentication) SetMutualAuthentication(v *CertificateAuthentication) *ClientVpnAuthentication { - s.MutualAuthentication = v - return s -} - -// SetType sets the Type field's value. -func (s *ClientVpnAuthentication) SetType(v string) *ClientVpnAuthentication { - s.Type = &v - return s -} - -// Describes the authentication method to be used by a Client VPN endpoint. -// Client VPN supports Active Directory and mutual authentication. For more -// information, see Authentication (https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/authentication-authrization.html#client-authentication) -// in the AWS Client VPN Administrator Guide. -type ClientVpnAuthenticationRequest struct { - _ struct{} `type:"structure"` - - // Information about the Active Directory to be used, if applicable. You must - // provide this information if Type is directory-service-authentication. - ActiveDirectory *DirectoryServiceAuthenticationRequest `type:"structure"` - - // Information about the authentication certificates to be used, if applicable. - // You must provide this information if Type is certificate-authentication. - MutualAuthentication *CertificateAuthenticationRequest `type:"structure"` - - // The type of client authentication to be used. Specify certificate-authentication - // to use certificate-based authentication, or directory-service-authentication - // to use Active Directory authentication. - Type *string `type:"string" enum:"ClientVpnAuthenticationType"` -} - -// String returns the string representation -func (s ClientVpnAuthenticationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnAuthenticationRequest) GoString() string { - return s.String() -} - -// SetActiveDirectory sets the ActiveDirectory field's value. -func (s *ClientVpnAuthenticationRequest) SetActiveDirectory(v *DirectoryServiceAuthenticationRequest) *ClientVpnAuthenticationRequest { - s.ActiveDirectory = v - return s -} - -// SetMutualAuthentication sets the MutualAuthentication field's value. -func (s *ClientVpnAuthenticationRequest) SetMutualAuthentication(v *CertificateAuthenticationRequest) *ClientVpnAuthenticationRequest { - s.MutualAuthentication = v - return s -} - -// SetType sets the Type field's value. -func (s *ClientVpnAuthenticationRequest) SetType(v string) *ClientVpnAuthenticationRequest { - s.Type = &v - return s -} - -// Describes the state of an authorization rule. -type ClientVpnAuthorizationRuleStatus struct { - _ struct{} `type:"structure"` - - // The state of the authorization rule. - Code *string `locationName:"code" type:"string" enum:"ClientVpnAuthorizationRuleStatusCode"` - - // A message about the status of the authorization rule, if applicable. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s ClientVpnAuthorizationRuleStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnAuthorizationRuleStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *ClientVpnAuthorizationRuleStatus) SetCode(v string) *ClientVpnAuthorizationRuleStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *ClientVpnAuthorizationRuleStatus) SetMessage(v string) *ClientVpnAuthorizationRuleStatus { - s.Message = &v - return s -} - -// Describes a client connection. -type ClientVpnConnection struct { - _ struct{} `type:"structure"` - - // The IP address of the client. - ClientIp *string `locationName:"clientIp" type:"string"` - - // The ID of the Client VPN endpoint to which the client is connected. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // The common name associated with the client. This is either the name of the - // client certificate, or the Active Directory user name. - CommonName *string `locationName:"commonName" type:"string"` - - // The date and time the client connection was terminated. - ConnectionEndTime *string `locationName:"connectionEndTime" type:"string"` - - // The date and time the client connection was established. - ConnectionEstablishedTime *string `locationName:"connectionEstablishedTime" type:"string"` - - // The ID of the client connection. - ConnectionId *string `locationName:"connectionId" type:"string"` - - // The number of bytes received by the client. - EgressBytes *string `locationName:"egressBytes" type:"string"` - - // The number of packets received by the client. - EgressPackets *string `locationName:"egressPackets" type:"string"` - - // The number of bytes sent by the client. - IngressBytes *string `locationName:"ingressBytes" type:"string"` - - // The number of packets sent by the client. - IngressPackets *string `locationName:"ingressPackets" type:"string"` - - // The current state of the client connection. - Status *ClientVpnConnectionStatus `locationName:"status" type:"structure"` - - // The current date and time. - Timestamp *string `locationName:"timestamp" type:"string"` - - // The username of the client who established the client connection. This information - // is only provided if Active Directory client authentication is used. - Username *string `locationName:"username" type:"string"` -} - -// String returns the string representation -func (s ClientVpnConnection) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnConnection) GoString() string { - return s.String() -} - -// SetClientIp sets the ClientIp field's value. -func (s *ClientVpnConnection) SetClientIp(v string) *ClientVpnConnection { - s.ClientIp = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ClientVpnConnection) SetClientVpnEndpointId(v string) *ClientVpnConnection { - s.ClientVpnEndpointId = &v - return s -} - -// SetCommonName sets the CommonName field's value. -func (s *ClientVpnConnection) SetCommonName(v string) *ClientVpnConnection { - s.CommonName = &v - return s -} - -// SetConnectionEndTime sets the ConnectionEndTime field's value. -func (s *ClientVpnConnection) SetConnectionEndTime(v string) *ClientVpnConnection { - s.ConnectionEndTime = &v - return s -} - -// SetConnectionEstablishedTime sets the ConnectionEstablishedTime field's value. -func (s *ClientVpnConnection) SetConnectionEstablishedTime(v string) *ClientVpnConnection { - s.ConnectionEstablishedTime = &v - return s -} - -// SetConnectionId sets the ConnectionId field's value. -func (s *ClientVpnConnection) SetConnectionId(v string) *ClientVpnConnection { - s.ConnectionId = &v - return s -} - -// SetEgressBytes sets the EgressBytes field's value. -func (s *ClientVpnConnection) SetEgressBytes(v string) *ClientVpnConnection { - s.EgressBytes = &v - return s -} - -// SetEgressPackets sets the EgressPackets field's value. -func (s *ClientVpnConnection) SetEgressPackets(v string) *ClientVpnConnection { - s.EgressPackets = &v - return s -} - -// SetIngressBytes sets the IngressBytes field's value. -func (s *ClientVpnConnection) SetIngressBytes(v string) *ClientVpnConnection { - s.IngressBytes = &v - return s -} - -// SetIngressPackets sets the IngressPackets field's value. -func (s *ClientVpnConnection) SetIngressPackets(v string) *ClientVpnConnection { - s.IngressPackets = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *ClientVpnConnection) SetStatus(v *ClientVpnConnectionStatus) *ClientVpnConnection { - s.Status = v - return s -} - -// SetTimestamp sets the Timestamp field's value. -func (s *ClientVpnConnection) SetTimestamp(v string) *ClientVpnConnection { - s.Timestamp = &v - return s -} - -// SetUsername sets the Username field's value. -func (s *ClientVpnConnection) SetUsername(v string) *ClientVpnConnection { - s.Username = &v - return s -} - -// Describes the status of a client connection. -type ClientVpnConnectionStatus struct { - _ struct{} `type:"structure"` - - // The state of the client connection. - Code *string `locationName:"code" type:"string" enum:"ClientVpnConnectionStatusCode"` - - // A message about the status of the client connection, if applicable. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s ClientVpnConnectionStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnConnectionStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *ClientVpnConnectionStatus) SetCode(v string) *ClientVpnConnectionStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *ClientVpnConnectionStatus) SetMessage(v string) *ClientVpnConnectionStatus { - s.Message = &v - return s -} - -// Describes a Client VPN endpoint. -type ClientVpnEndpoint struct { - _ struct{} `type:"structure"` - - // Information about the associated target networks. A target network is a subnet - // in a VPC. - // - // Deprecated: This property is deprecated. To view the target networks associated with a Client VPN endpoint, call DescribeClientVpnTargetNetworks and inspect the clientVpnTargetNetworks response element. - AssociatedTargetNetworks []*AssociatedTargetNetwork `locationName:"associatedTargetNetwork" locationNameList:"item" deprecated:"true" type:"list"` - - // Information about the authentication method used by the Client VPN endpoint. - AuthenticationOptions []*ClientVpnAuthentication `locationName:"authenticationOptions" locationNameList:"item" type:"list"` - - // The IPv4 address range, in CIDR notation, from which client IP addresses - // are assigned. - ClientCidrBlock *string `locationName:"clientCidrBlock" type:"string"` - - // The ID of the Client VPN endpoint. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // Information about the client connection logging options for the Client VPN - // endpoint. - ConnectionLogOptions *ConnectionLogResponseOptions `locationName:"connectionLogOptions" type:"structure"` - - // The date and time the Client VPN endpoint was created. - CreationTime *string `locationName:"creationTime" type:"string"` - - // The date and time the Client VPN endpoint was deleted, if applicable. - DeletionTime *string `locationName:"deletionTime" type:"string"` - - // A brief description of the endpoint. - Description *string `locationName:"description" type:"string"` - - // The DNS name to be used by clients when connecting to the Client VPN endpoint. - DnsName *string `locationName:"dnsName" type:"string"` - - // Information about the DNS servers to be used for DNS resolution. - DnsServers []*string `locationName:"dnsServer" locationNameList:"item" type:"list"` - - // The ARN of the server certificate. - ServerCertificateArn *string `locationName:"serverCertificateArn" type:"string"` - - // Indicates whether VPN split tunneling is supported. - SplitTunnel *bool `locationName:"splitTunnel" type:"boolean"` - - // The current state of the Client VPN endpoint. - Status *ClientVpnEndpointStatus `locationName:"status" type:"structure"` - - // Any tags assigned to the Client VPN endpoint. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The transport protocol used by the Client VPN endpoint. - TransportProtocol *string `locationName:"transportProtocol" type:"string" enum:"TransportProtocol"` - - // The protocol used by the VPN session. - VpnProtocol *string `locationName:"vpnProtocol" type:"string" enum:"VpnProtocol"` -} - -// String returns the string representation -func (s ClientVpnEndpoint) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnEndpoint) GoString() string { - return s.String() -} - -// SetAssociatedTargetNetworks sets the AssociatedTargetNetworks field's value. -func (s *ClientVpnEndpoint) SetAssociatedTargetNetworks(v []*AssociatedTargetNetwork) *ClientVpnEndpoint { - s.AssociatedTargetNetworks = v - return s -} - -// SetAuthenticationOptions sets the AuthenticationOptions field's value. -func (s *ClientVpnEndpoint) SetAuthenticationOptions(v []*ClientVpnAuthentication) *ClientVpnEndpoint { - s.AuthenticationOptions = v - return s -} - -// SetClientCidrBlock sets the ClientCidrBlock field's value. -func (s *ClientVpnEndpoint) SetClientCidrBlock(v string) *ClientVpnEndpoint { - s.ClientCidrBlock = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ClientVpnEndpoint) SetClientVpnEndpointId(v string) *ClientVpnEndpoint { - s.ClientVpnEndpointId = &v - return s -} - -// SetConnectionLogOptions sets the ConnectionLogOptions field's value. -func (s *ClientVpnEndpoint) SetConnectionLogOptions(v *ConnectionLogResponseOptions) *ClientVpnEndpoint { - s.ConnectionLogOptions = v - return s -} - -// SetCreationTime sets the CreationTime field's value. -func (s *ClientVpnEndpoint) SetCreationTime(v string) *ClientVpnEndpoint { - s.CreationTime = &v - return s -} - -// SetDeletionTime sets the DeletionTime field's value. -func (s *ClientVpnEndpoint) SetDeletionTime(v string) *ClientVpnEndpoint { - s.DeletionTime = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *ClientVpnEndpoint) SetDescription(v string) *ClientVpnEndpoint { - s.Description = &v - return s -} - -// SetDnsName sets the DnsName field's value. -func (s *ClientVpnEndpoint) SetDnsName(v string) *ClientVpnEndpoint { - s.DnsName = &v - return s -} - -// SetDnsServers sets the DnsServers field's value. -func (s *ClientVpnEndpoint) SetDnsServers(v []*string) *ClientVpnEndpoint { - s.DnsServers = v - return s -} - -// SetServerCertificateArn sets the ServerCertificateArn field's value. -func (s *ClientVpnEndpoint) SetServerCertificateArn(v string) *ClientVpnEndpoint { - s.ServerCertificateArn = &v - return s -} - -// SetSplitTunnel sets the SplitTunnel field's value. -func (s *ClientVpnEndpoint) SetSplitTunnel(v bool) *ClientVpnEndpoint { - s.SplitTunnel = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *ClientVpnEndpoint) SetStatus(v *ClientVpnEndpointStatus) *ClientVpnEndpoint { - s.Status = v - return s -} - -// SetTags sets the Tags field's value. -func (s *ClientVpnEndpoint) SetTags(v []*Tag) *ClientVpnEndpoint { - s.Tags = v - return s -} - -// SetTransportProtocol sets the TransportProtocol field's value. -func (s *ClientVpnEndpoint) SetTransportProtocol(v string) *ClientVpnEndpoint { - s.TransportProtocol = &v - return s -} - -// SetVpnProtocol sets the VpnProtocol field's value. -func (s *ClientVpnEndpoint) SetVpnProtocol(v string) *ClientVpnEndpoint { - s.VpnProtocol = &v - return s -} - -// Describes the state of a Client VPN endpoint. -type ClientVpnEndpointStatus struct { - _ struct{} `type:"structure"` - - // The state of the Client VPN endpoint. Possible states include: - // - // * pending-associate - The Client VPN endpoint has been created but no - // target networks have been associated. The Client VPN endpoint cannot accept - // connections. - // - // * available - The Client VPN endpoint has been created and a target network - // has been associated. The Client VPN endpoint can accept connections. - // - // * deleting - The Client VPN endpoint is being deleted. The Client VPN - // endpoint cannot accept connections. - // - // * deleted - The Client VPN endpoint has been deleted. The Client VPN endpoint - // cannot accept connections. - Code *string `locationName:"code" type:"string" enum:"ClientVpnEndpointStatusCode"` - - // A message about the status of the Client VPN endpoint. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s ClientVpnEndpointStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnEndpointStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *ClientVpnEndpointStatus) SetCode(v string) *ClientVpnEndpointStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *ClientVpnEndpointStatus) SetMessage(v string) *ClientVpnEndpointStatus { - s.Message = &v - return s -} - -// Information about a Client VPN endpoint route. -type ClientVpnRoute struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint with which the route is associated. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // A brief description of the route. - Description *string `locationName:"description" type:"string"` - - // The IPv4 address range, in CIDR notation, of the route destination. - DestinationCidr *string `locationName:"destinationCidr" type:"string"` - - // Indicates how the route was associated with the Client VPN endpoint. associate - // indicates that the route was automatically added when the target network - // was associated with the Client VPN endpoint. add-route indicates that the - // route was manually added using the CreateClientVpnRoute action. - Origin *string `locationName:"origin" type:"string"` - - // The current state of the route. - Status *ClientVpnRouteStatus `locationName:"status" type:"structure"` - - // The ID of the subnet through which traffic is routed. - TargetSubnet *string `locationName:"targetSubnet" type:"string"` - - // The route type. - Type *string `locationName:"type" type:"string"` -} - -// String returns the string representation -func (s ClientVpnRoute) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnRoute) GoString() string { - return s.String() -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ClientVpnRoute) SetClientVpnEndpointId(v string) *ClientVpnRoute { - s.ClientVpnEndpointId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *ClientVpnRoute) SetDescription(v string) *ClientVpnRoute { - s.Description = &v - return s -} - -// SetDestinationCidr sets the DestinationCidr field's value. -func (s *ClientVpnRoute) SetDestinationCidr(v string) *ClientVpnRoute { - s.DestinationCidr = &v - return s -} - -// SetOrigin sets the Origin field's value. -func (s *ClientVpnRoute) SetOrigin(v string) *ClientVpnRoute { - s.Origin = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *ClientVpnRoute) SetStatus(v *ClientVpnRouteStatus) *ClientVpnRoute { - s.Status = v - return s -} - -// SetTargetSubnet sets the TargetSubnet field's value. -func (s *ClientVpnRoute) SetTargetSubnet(v string) *ClientVpnRoute { - s.TargetSubnet = &v - return s -} - -// SetType sets the Type field's value. -func (s *ClientVpnRoute) SetType(v string) *ClientVpnRoute { - s.Type = &v - return s -} - -// Describes the state of a Client VPN endpoint route. -type ClientVpnRouteStatus struct { - _ struct{} `type:"structure"` - - // The state of the Client VPN endpoint route. - Code *string `locationName:"code" type:"string" enum:"ClientVpnRouteStatusCode"` - - // A message about the status of the Client VPN endpoint route, if applicable. - Message *string `locationName:"message" type:"string"` -} - -// String returns the string representation -func (s ClientVpnRouteStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ClientVpnRouteStatus) GoString() string { - return s.String() -} - -// SetCode sets the Code field's value. -func (s *ClientVpnRouteStatus) SetCode(v string) *ClientVpnRouteStatus { - s.Code = &v - return s -} - -// SetMessage sets the Message field's value. -func (s *ClientVpnRouteStatus) SetMessage(v string) *ClientVpnRouteStatus { - s.Message = &v - return s -} - +// Contains the parameters for ConfirmProductInstance. type ConfirmProductInstanceInput struct { _ struct{} `type:"structure"` @@ -37765,6 +26559,7 @@ func (s *ConfirmProductInstanceInput) SetProductCode(v string) *ConfirmProductIn return s } +// Contains the output of ConfirmProductInstance. type ConfirmProductInstanceOutput struct { _ struct{} `type:"structure"` @@ -37799,95 +26594,6 @@ func (s *ConfirmProductInstanceOutput) SetReturn(v bool) *ConfirmProductInstance return s } -// Describes the client connection logging options for the Client VPN endpoint. -type ConnectionLogOptions struct { - _ struct{} `type:"structure"` - - // The name of the CloudWatch Logs log group. - CloudwatchLogGroup *string `type:"string"` - - // The name of the CloudWatch Logs log stream to which the connection data is - // published. - CloudwatchLogStream *string `type:"string"` - - // Indicates whether connection logging is enabled. - Enabled *bool `type:"boolean"` -} - -// String returns the string representation -func (s ConnectionLogOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ConnectionLogOptions) GoString() string { - return s.String() -} - -// SetCloudwatchLogGroup sets the CloudwatchLogGroup field's value. -func (s *ConnectionLogOptions) SetCloudwatchLogGroup(v string) *ConnectionLogOptions { - s.CloudwatchLogGroup = &v - return s -} - -// SetCloudwatchLogStream sets the CloudwatchLogStream field's value. -func (s *ConnectionLogOptions) SetCloudwatchLogStream(v string) *ConnectionLogOptions { - s.CloudwatchLogStream = &v - return s -} - -// SetEnabled sets the Enabled field's value. -func (s *ConnectionLogOptions) SetEnabled(v bool) *ConnectionLogOptions { - s.Enabled = &v - return s -} - -// Information about the client connection logging options for a Client VPN -// endpoint. -type ConnectionLogResponseOptions struct { - _ struct{} `type:"structure"` - - // The name of the Amazon CloudWatch Logs log group to which connection logging - // data is published. - CloudwatchLogGroup *string `type:"string"` - - // The name of the Amazon CloudWatch Logs log stream to which connection logging - // data is published. - CloudwatchLogStream *string `type:"string"` - - // Indicates whether client connection logging is enabled for the Client VPN - // endpoint. - Enabled *bool `type:"boolean"` -} - -// String returns the string representation -func (s ConnectionLogResponseOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ConnectionLogResponseOptions) GoString() string { - return s.String() -} - -// SetCloudwatchLogGroup sets the CloudwatchLogGroup field's value. -func (s *ConnectionLogResponseOptions) SetCloudwatchLogGroup(v string) *ConnectionLogResponseOptions { - s.CloudwatchLogGroup = &v - return s -} - -// SetCloudwatchLogStream sets the CloudwatchLogStream field's value. -func (s *ConnectionLogResponseOptions) SetCloudwatchLogStream(v string) *ConnectionLogResponseOptions { - s.CloudwatchLogStream = &v - return s -} - -// SetEnabled sets the Enabled field's value. -func (s *ConnectionLogResponseOptions) SetEnabled(v bool) *ConnectionLogResponseOptions { - s.Enabled = &v - return s -} - // Describes a connection notification for a VPC endpoint or VPC endpoint service. type ConnectionNotification struct { _ struct{} `type:"structure"` @@ -38052,7 +26758,7 @@ type CopyFpgaImageInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). + // of the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // The description for the new AFI. @@ -38072,7 +26778,7 @@ type CopyFpgaImageInput struct { // SourceFpgaImageId is a required field SourceFpgaImageId *string `type:"string" required:"true"` - // The Region that contains the source AFI. + // The region that contains the source AFI. // // SourceRegion is a required field SourceRegion *string `type:"string" required:"true"` @@ -38168,11 +26874,11 @@ type CopyImageInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure idempotency of the - // request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) // in the Amazon Elastic Compute Cloud User Guide. ClientToken *string `type:"string"` - // A description for the new AMI in the destination Region. + // A description for the new AMI in the destination region. Description *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -38182,11 +26888,9 @@ type CopyImageInput struct { DryRun *bool `locationName:"dryRun" type:"boolean"` // Specifies whether the destination snapshots of the copied image should be - // encrypted. You can encrypt a copy of an unencrypted snapshot, but you cannot - // create an unencrypted copy of an encrypted snapshot. The default CMK for - // EBS is used unless you specify a non-default AWS Key Management Service (AWS - // KMS) CMK using KmsKeyId. For more information, see Amazon EBS Encryption - // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) + // encrypted. The default CMK for EBS is used unless a non-default AWS Key Management + // Service (AWS KMS) CMK is specified with KmsKeyId. For more information, see + // Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. Encrypted *bool `locationName:"encrypted" type:"boolean"` @@ -38196,26 +26900,31 @@ type CopyImageInput struct { // the default CMK for EBS is used. If a KmsKeyId is specified, the Encrypted // flag must also be set. // - // To specify a CMK, use its key ID, Amazon Resource Name (ARN), alias name, - // or alias ARN. When using an alias name, prefix it with "alias/". For example: + // The CMK identifier may be provided in any of the following formats: // - // * Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab + // * Key ID // - // * Key ARN: arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab + // * Key alias, in the form alias/ExampleAlias // - // * Alias name: alias/ExampleAlias + // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed + // by the region of the CMK, the AWS account ID of the CMK owner, the key + // namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. + // + // + // * ARN using key alias. The alias ARN contains the arn:aws:kms namespace, + // followed by the region of the CMK, the AWS account ID of the CMK owner, + // the alias namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. // - // * Alias ARN: arn:aws:kms:us-east-2:111122223333:alias/ExampleAlias // // AWS parses KmsKeyId asynchronously, meaning that the action you call may // appear to complete even though you provided an invalid identifier. This action // will eventually report failure. // - // The specified CMK must exist in the Region that the snapshot is being copied + // The specified CMK must exist in the region that the snapshot is being copied // to. KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // The name of the new AMI in the destination Region. + // The name of the new AMI in the destination region. // // Name is a required field Name *string `type:"string" required:"true"` @@ -38225,7 +26934,7 @@ type CopyImageInput struct { // SourceImageId is a required field SourceImageId *string `type:"string" required:"true"` - // The name of the Region that contains the AMI to copy. + // The name of the region that contains the AMI to copy. // // SourceRegion is a required field SourceRegion *string `type:"string" required:"true"` @@ -38339,13 +27048,13 @@ type CopySnapshotInput struct { // A description for the EBS snapshot. Description *string `type:"string"` - // The destination Region to use in the PresignedUrl parameter of a snapshot + // The destination region to use in the PresignedUrl parameter of a snapshot // copy operation. This parameter is only valid for specifying the destination - // Region in a PresignedUrl parameter, where it is required. + // region in a PresignedUrl parameter, where it is required. // // The snapshot copy is sent to the regional endpoint that you sent the HTTP // request to (for example, ec2.us-east-1.amazonaws.com). With the AWS CLI, - // this is specified using the --region parameter or the default Region in your + // this is specified using the --region parameter or the default region in your // AWS configuration file. DestinationRegion *string `locationName:"destinationRegion" type:"string"` @@ -38355,50 +27064,58 @@ type CopySnapshotInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // To encrypt a copy of an unencrypted snapshot if encryption by default is - // not enabled, enable encryption using this parameter. Otherwise, omit this - // parameter. Encrypted snapshots are encrypted, even if you omit this parameter - // and encryption by default is not enabled. You cannot set this parameter to - // false. For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) - // in the Amazon Elastic Compute Cloud User Guide. + // Specifies whether the destination snapshot should be encrypted. You can encrypt + // a copy of an unencrypted snapshot using this flag, but you cannot use it + // to create an unencrypted copy from an encrypted snapshot. Your default CMK + // for EBS is used unless a non-default AWS Key Management Service (AWS KMS) + // CMK is specified with KmsKeyId. For more information, see Amazon EBS Encryption + // (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) in + // the Amazon Elastic Compute Cloud User Guide. Encrypted *bool `locationName:"encrypted" type:"boolean"` - // The identifier of the AWS Key Management Service (AWS KMS) customer master - // key (CMK) to use for Amazon EBS encryption. If this parameter is not specified, - // your AWS managed CMK for EBS is used. If KmsKeyId is specified, the encrypted - // state must be true. + // An identifier for the AWS Key Management Service (AWS KMS) customer master + // key (CMK) to use when creating the encrypted volume. This parameter is only + // required if you want to use a non-default CMK; if this parameter is not specified, + // the default CMK for EBS is used. If a KmsKeyId is specified, the Encrypted + // flag must also be set. // - // You can specify the CMK using any of the following: + // The CMK identifier may be provided in any of the following formats: // - // * Key ID. For example, key/1234abcd-12ab-34cd-56ef-1234567890ab. + // * Key ID // - // * Key alias. For example, alias/ExampleAlias. + // * Key alias // - // * Key ARN. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. + // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed + // by the region of the CMK, the AWS account ID of the CMK owner, the key + // namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. // - // * Alias ARN. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. // - // AWS authenticates the CMK asynchronously. Therefore, if you specify an ID, - // alias, or ARN that is not valid, the action can appear to complete, but eventually - // fails. + // * ARN using key alias. The alias ARN contains the arn:aws:kms namespace, + // followed by the region of the CMK, the AWS account ID of the CMK owner, + // the alias namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. + // + // + // AWS parses KmsKeyId asynchronously, meaning that the action you call may + // appear to complete even though you provided an invalid identifier. The action + // will eventually fail. KmsKeyId *string `locationName:"kmsKeyId" type:"string"` // When you copy an encrypted source snapshot using the Amazon EC2 Query API, // you must supply a pre-signed URL. This parameter is optional for unencrypted - // snapshots. For more information, see Query Requests (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Query-Requests.html). + // snapshots. For more information, see Query Requests (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Query-Requests.html). // // The PresignedUrl should use the snapshot source endpoint, the CopySnapshot // action, and include the SourceRegion, SourceSnapshotId, and DestinationRegion // parameters. The PresignedUrl must be signed using AWS Signature Version 4. // Because EBS snapshots are stored in Amazon S3, the signing algorithm for // this parameter uses the same logic that is described in Authenticating Requests - // by Using Query Parameters (AWS Signature Version 4) (https://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html) + // by Using Query Parameters (AWS Signature Version 4) (http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html) // in the Amazon Simple Storage Service API Reference. An invalid or improperly // signed PresignedUrl will cause the copy operation to fail asynchronously, // and the snapshot will move to an error state. PresignedUrl *string `locationName:"presignedUrl" type:"string"` - // The ID of the Region that contains the snapshot to be copied. + // The ID of the region that contains the snapshot to be copied. // // SourceRegion is a required field SourceRegion *string `type:"string" required:"true"` @@ -38576,573 +27293,6 @@ func (s *CpuOptionsRequest) SetThreadsPerCore(v int64) *CpuOptionsRequest { return s } -type CreateCapacityReservationInput struct { - _ struct{} `type:"structure"` - - // The Availability Zone in which to create the Capacity Reservation. - // - // AvailabilityZone is a required field - AvailabilityZone *string `type:"string" required:"true"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - // - // Constraint: Maximum 64 ASCII characters. - ClientToken *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // Indicates whether the Capacity Reservation supports EBS-optimized instances. - // This optimization provides dedicated throughput to Amazon EBS and an optimized - // configuration stack to provide optimal I/O performance. This optimization - // isn't available with all instance types. Additional usage charges apply when - // using an EBS- optimized instance. - EbsOptimized *bool `type:"boolean"` - - // The date and time at which the Capacity Reservation expires. When a Capacity - // Reservation expires, the reserved capacity is released and you can no longer - // launch instances into it. The Capacity Reservation's state changes to expired - // when it reaches its end date and time. - // - // You must provide an EndDate value if EndDateType is limited. Omit EndDate - // if EndDateType is unlimited. - // - // If the EndDateType is limited, the Capacity Reservation is cancelled within - // an hour from the specified time. For example, if you specify 5/31/2019, 13:30:55, - // the Capacity Reservation is guaranteed to end between 13:30:55 and 14:30:55 - // on 5/31/2019. - EndDate *time.Time `type:"timestamp"` - - // Indicates the way in which the Capacity Reservation ends. A Capacity Reservation - // can have one of the following end types: - // - // * unlimited - The Capacity Reservation remains active until you explicitly - // cancel it. Do not provide an EndDate if the EndDateType is unlimited. - // - // * limited - The Capacity Reservation expires automatically at a specified - // date and time. You must provide an EndDate value if the EndDateType value - // is limited. - EndDateType *string `type:"string" enum:"EndDateType"` - - // Indicates whether the Capacity Reservation supports instances with temporary, - // block-level storage. - EphemeralStorage *bool `type:"boolean"` - - // The number of instances for which to reserve capacity. - // - // InstanceCount is a required field - InstanceCount *int64 `type:"integer" required:"true"` - - // Indicates the type of instance launches that the Capacity Reservation accepts. - // The options include: - // - // * open - The Capacity Reservation automatically matches all instances - // that have matching attributes (instance type, platform, and Availability - // Zone). Instances that have matching attributes run in the Capacity Reservation - // automatically without specifying any additional parameters. - // - // * targeted - The Capacity Reservation only accepts instances that have - // matching attributes (instance type, platform, and Availability Zone), - // and explicitly target the Capacity Reservation. This ensures that only - // permitted instances can use the reserved capacity. - // - // Default: open - InstanceMatchCriteria *string `type:"string" enum:"InstanceMatchCriteria"` - - // The type of operating system for which to reserve capacity. - // - // InstancePlatform is a required field - InstancePlatform *string `type:"string" required:"true" enum:"CapacityReservationInstancePlatform"` - - // The instance type for which to reserve capacity. For more information, see - // Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) - // in the Amazon Elastic Compute Cloud User Guide. - // - // InstanceType is a required field - InstanceType *string `type:"string" required:"true"` - - // The tags to apply to the Capacity Reservation during launch. - TagSpecifications []*TagSpecification `locationNameList:"item" type:"list"` - - // Indicates the tenancy of the Capacity Reservation. A Capacity Reservation - // can have one of the following tenancy settings: - // - // * default - The Capacity Reservation is created on hardware that is shared - // with other AWS accounts. - // - // * dedicated - The Capacity Reservation is created on single-tenant hardware - // that is dedicated to a single AWS account. - Tenancy *string `type:"string" enum:"CapacityReservationTenancy"` -} - -// String returns the string representation -func (s CreateCapacityReservationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCapacityReservationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateCapacityReservationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateCapacityReservationInput"} - if s.AvailabilityZone == nil { - invalidParams.Add(request.NewErrParamRequired("AvailabilityZone")) - } - if s.InstanceCount == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceCount")) - } - if s.InstancePlatform == nil { - invalidParams.Add(request.NewErrParamRequired("InstancePlatform")) - } - if s.InstanceType == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceType")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAvailabilityZone sets the AvailabilityZone field's value. -func (s *CreateCapacityReservationInput) SetAvailabilityZone(v string) *CreateCapacityReservationInput { - s.AvailabilityZone = &v - return s -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateCapacityReservationInput) SetClientToken(v string) *CreateCapacityReservationInput { - s.ClientToken = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateCapacityReservationInput) SetDryRun(v bool) *CreateCapacityReservationInput { - s.DryRun = &v - return s -} - -// SetEbsOptimized sets the EbsOptimized field's value. -func (s *CreateCapacityReservationInput) SetEbsOptimized(v bool) *CreateCapacityReservationInput { - s.EbsOptimized = &v - return s -} - -// SetEndDate sets the EndDate field's value. -func (s *CreateCapacityReservationInput) SetEndDate(v time.Time) *CreateCapacityReservationInput { - s.EndDate = &v - return s -} - -// SetEndDateType sets the EndDateType field's value. -func (s *CreateCapacityReservationInput) SetEndDateType(v string) *CreateCapacityReservationInput { - s.EndDateType = &v - return s -} - -// SetEphemeralStorage sets the EphemeralStorage field's value. -func (s *CreateCapacityReservationInput) SetEphemeralStorage(v bool) *CreateCapacityReservationInput { - s.EphemeralStorage = &v - return s -} - -// SetInstanceCount sets the InstanceCount field's value. -func (s *CreateCapacityReservationInput) SetInstanceCount(v int64) *CreateCapacityReservationInput { - s.InstanceCount = &v - return s -} - -// SetInstanceMatchCriteria sets the InstanceMatchCriteria field's value. -func (s *CreateCapacityReservationInput) SetInstanceMatchCriteria(v string) *CreateCapacityReservationInput { - s.InstanceMatchCriteria = &v - return s -} - -// SetInstancePlatform sets the InstancePlatform field's value. -func (s *CreateCapacityReservationInput) SetInstancePlatform(v string) *CreateCapacityReservationInput { - s.InstancePlatform = &v - return s -} - -// SetInstanceType sets the InstanceType field's value. -func (s *CreateCapacityReservationInput) SetInstanceType(v string) *CreateCapacityReservationInput { - s.InstanceType = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateCapacityReservationInput) SetTagSpecifications(v []*TagSpecification) *CreateCapacityReservationInput { - s.TagSpecifications = v - return s -} - -// SetTenancy sets the Tenancy field's value. -func (s *CreateCapacityReservationInput) SetTenancy(v string) *CreateCapacityReservationInput { - s.Tenancy = &v - return s -} - -type CreateCapacityReservationOutput struct { - _ struct{} `type:"structure"` - - // Information about the Capacity Reservation. - CapacityReservation *CapacityReservation `locationName:"capacityReservation" type:"structure"` -} - -// String returns the string representation -func (s CreateCapacityReservationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateCapacityReservationOutput) GoString() string { - return s.String() -} - -// SetCapacityReservation sets the CapacityReservation field's value. -func (s *CreateCapacityReservationOutput) SetCapacityReservation(v *CapacityReservation) *CreateCapacityReservationOutput { - s.CapacityReservation = v - return s -} - -type CreateClientVpnEndpointInput struct { - _ struct{} `type:"structure"` - - // Information about the authentication method to be used to authenticate clients. - // - // AuthenticationOptions is a required field - AuthenticationOptions []*ClientVpnAuthenticationRequest `locationName:"Authentication" type:"list" required:"true"` - - // The IPv4 address range, in CIDR notation, from which to assign client IP - // addresses. The address range cannot overlap with the local CIDR of the VPC - // in which the associated subnet is located, or the routes that you add manually. - // The address range cannot be changed after the Client VPN endpoint has been - // created. The CIDR block should be /22 or greater. - // - // ClientCidrBlock is a required field - ClientCidrBlock *string `type:"string" required:"true"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // Information about the client connection logging options. - // - // If you enable client connection logging, data about client connections is - // sent to a Cloudwatch Logs log stream. The following information is logged: - // - // * Client connection requests - // - // * Client connection results (successful and unsuccessful) - // - // * Reasons for unsuccessful client connection requests - // - // * Client connection termination time - // - // ConnectionLogOptions is a required field - ConnectionLogOptions *ConnectionLogOptions `type:"structure" required:"true"` - - // A brief description of the Client VPN endpoint. - Description *string `type:"string"` - - // Information about the DNS servers to be used for DNS resolution. A Client - // VPN endpoint can have up to two DNS servers. If no DNS server is specified, - // the DNS address of the VPC that is to be associated with Client VPN endpoint - // is used as the DNS server. - DnsServers []*string `locationNameList:"item" type:"list"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ARN of the server certificate. For more information, see the AWS Certificate - // Manager User Guide (https://docs.aws.amazon.com/acm/latest/userguide/). - // - // ServerCertificateArn is a required field - ServerCertificateArn *string `type:"string" required:"true"` - - // The tags to apply to the Client VPN endpoint during creation. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` - - // The transport protocol to be used by the VPN session. - // - // Default value: udp - TransportProtocol *string `type:"string" enum:"TransportProtocol"` -} - -// String returns the string representation -func (s CreateClientVpnEndpointInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateClientVpnEndpointInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateClientVpnEndpointInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateClientVpnEndpointInput"} - if s.AuthenticationOptions == nil { - invalidParams.Add(request.NewErrParamRequired("AuthenticationOptions")) - } - if s.ClientCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("ClientCidrBlock")) - } - if s.ConnectionLogOptions == nil { - invalidParams.Add(request.NewErrParamRequired("ConnectionLogOptions")) - } - if s.ServerCertificateArn == nil { - invalidParams.Add(request.NewErrParamRequired("ServerCertificateArn")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAuthenticationOptions sets the AuthenticationOptions field's value. -func (s *CreateClientVpnEndpointInput) SetAuthenticationOptions(v []*ClientVpnAuthenticationRequest) *CreateClientVpnEndpointInput { - s.AuthenticationOptions = v - return s -} - -// SetClientCidrBlock sets the ClientCidrBlock field's value. -func (s *CreateClientVpnEndpointInput) SetClientCidrBlock(v string) *CreateClientVpnEndpointInput { - s.ClientCidrBlock = &v - return s -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateClientVpnEndpointInput) SetClientToken(v string) *CreateClientVpnEndpointInput { - s.ClientToken = &v - return s -} - -// SetConnectionLogOptions sets the ConnectionLogOptions field's value. -func (s *CreateClientVpnEndpointInput) SetConnectionLogOptions(v *ConnectionLogOptions) *CreateClientVpnEndpointInput { - s.ConnectionLogOptions = v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateClientVpnEndpointInput) SetDescription(v string) *CreateClientVpnEndpointInput { - s.Description = &v - return s -} - -// SetDnsServers sets the DnsServers field's value. -func (s *CreateClientVpnEndpointInput) SetDnsServers(v []*string) *CreateClientVpnEndpointInput { - s.DnsServers = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateClientVpnEndpointInput) SetDryRun(v bool) *CreateClientVpnEndpointInput { - s.DryRun = &v - return s -} - -// SetServerCertificateArn sets the ServerCertificateArn field's value. -func (s *CreateClientVpnEndpointInput) SetServerCertificateArn(v string) *CreateClientVpnEndpointInput { - s.ServerCertificateArn = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateClientVpnEndpointInput) SetTagSpecifications(v []*TagSpecification) *CreateClientVpnEndpointInput { - s.TagSpecifications = v - return s -} - -// SetTransportProtocol sets the TransportProtocol field's value. -func (s *CreateClientVpnEndpointInput) SetTransportProtocol(v string) *CreateClientVpnEndpointInput { - s.TransportProtocol = &v - return s -} - -type CreateClientVpnEndpointOutput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // The DNS name to be used by clients when establishing their VPN session. - DnsName *string `locationName:"dnsName" type:"string"` - - // The current state of the Client VPN endpoint. - Status *ClientVpnEndpointStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s CreateClientVpnEndpointOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateClientVpnEndpointOutput) GoString() string { - return s.String() -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *CreateClientVpnEndpointOutput) SetClientVpnEndpointId(v string) *CreateClientVpnEndpointOutput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDnsName sets the DnsName field's value. -func (s *CreateClientVpnEndpointOutput) SetDnsName(v string) *CreateClientVpnEndpointOutput { - s.DnsName = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *CreateClientVpnEndpointOutput) SetStatus(v *ClientVpnEndpointStatus) *CreateClientVpnEndpointOutput { - s.Status = v - return s -} - -type CreateClientVpnRouteInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The ID of the Client VPN endpoint to which to add the route. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // A brief description of the route. - Description *string `type:"string"` - - // The IPv4 address range, in CIDR notation, of the route destination. For example: - // - // * To add a route for Internet access, enter 0.0.0.0/0 - // - // * To add a route for a peered VPC, enter the peered VPC's IPv4 CIDR range - // - // * To add a route for an on-premises network, enter the AWS Site-to-Site - // VPN connection's IPv4 CIDR range - // - // Route address ranges cannot overlap with the CIDR range specified for client - // allocation. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the subnet through which you want to route traffic. The specified - // subnet must be an existing target network of the Client VPN endpoint. - // - // TargetVpcSubnetId is a required field - TargetVpcSubnetId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateClientVpnRouteInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateClientVpnRouteInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateClientVpnRouteInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateClientVpnRouteInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - if s.TargetVpcSubnetId == nil { - invalidParams.Add(request.NewErrParamRequired("TargetVpcSubnetId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateClientVpnRouteInput) SetClientToken(v string) *CreateClientVpnRouteInput { - s.ClientToken = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *CreateClientVpnRouteInput) SetClientVpnEndpointId(v string) *CreateClientVpnRouteInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateClientVpnRouteInput) SetDescription(v string) *CreateClientVpnRouteInput { - s.Description = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *CreateClientVpnRouteInput) SetDestinationCidrBlock(v string) *CreateClientVpnRouteInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateClientVpnRouteInput) SetDryRun(v bool) *CreateClientVpnRouteInput { - s.DryRun = &v - return s -} - -// SetTargetVpcSubnetId sets the TargetVpcSubnetId field's value. -func (s *CreateClientVpnRouteInput) SetTargetVpcSubnetId(v string) *CreateClientVpnRouteInput { - s.TargetVpcSubnetId = &v - return s -} - -type CreateClientVpnRouteOutput struct { - _ struct{} `type:"structure"` - - // The current state of the route. - Status *ClientVpnRouteStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s CreateClientVpnRouteOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateClientVpnRouteOutput) GoString() string { - return s.String() -} - -// SetStatus sets the Status field's value. -func (s *CreateClientVpnRouteOutput) SetStatus(v *ClientVpnRouteStatus) *CreateClientVpnRouteOutput { - s.Status = v - return s -} - // Contains the parameters for CreateCustomerGateway. type CreateCustomerGatewayInput struct { _ struct{} `type:"structure"` @@ -39322,6 +27472,7 @@ func (s *CreateDefaultSubnetOutput) SetSubnet(v *Subnet) *CreateDefaultSubnetOut return s } +// Contains the parameters for CreateDefaultVpc. type CreateDefaultVpcInput struct { _ struct{} `type:"structure"` @@ -39348,6 +27499,7 @@ func (s *CreateDefaultVpcInput) SetDryRun(v bool) *CreateDefaultVpcInput { return s } +// Contains the output of CreateDefaultVpc. type CreateDefaultVpcOutput struct { _ struct{} `type:"structure"` @@ -39371,6 +27523,7 @@ func (s *CreateDefaultVpcOutput) SetVpc(v *Vpc) *CreateDefaultVpcOutput { return s } +// Contains the parameters for CreateDhcpOptions. type CreateDhcpOptionsInput struct { _ struct{} `type:"structure"` @@ -39421,6 +27574,7 @@ func (s *CreateDhcpOptionsInput) SetDryRun(v bool) *CreateDhcpOptionsInput { return s } +// Contains the output of CreateDhcpOptions. type CreateDhcpOptionsOutput struct { _ struct{} `type:"structure"` @@ -39448,7 +27602,7 @@ type CreateEgressOnlyInternetGatewayInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -39537,67 +27691,11 @@ func (s *CreateEgressOnlyInternetGatewayOutput) SetEgressOnlyInternetGateway(v * return s } -// Describes the instances that could not be launched by the fleet. -type CreateFleetError struct { - _ struct{} `type:"structure"` - - // The error code that indicates why the instance could not be launched. For - // more information about error codes, see Error Codes (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html.html). - ErrorCode *string `locationName:"errorCode" type:"string"` - - // The error message that describes why the instance could not be launched. - // For more information about error messages, see ee Error Codes (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html.html). - ErrorMessage *string `locationName:"errorMessage" type:"string"` - - // The launch templates and overrides that were used for launching the instances. - // Any parameters that you specify in the Overrides override the same parameters - // in the launch template. - LaunchTemplateAndOverrides *LaunchTemplateAndOverridesResponse `locationName:"launchTemplateAndOverrides" type:"structure"` - - // Indicates if the instance that could not be launched was a Spot Instance - // or On-Demand Instance. - Lifecycle *string `locationName:"lifecycle" type:"string" enum:"InstanceLifecycle"` -} - -// String returns the string representation -func (s CreateFleetError) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateFleetError) GoString() string { - return s.String() -} - -// SetErrorCode sets the ErrorCode field's value. -func (s *CreateFleetError) SetErrorCode(v string) *CreateFleetError { - s.ErrorCode = &v - return s -} - -// SetErrorMessage sets the ErrorMessage field's value. -func (s *CreateFleetError) SetErrorMessage(v string) *CreateFleetError { - s.ErrorMessage = &v - return s -} - -// SetLaunchTemplateAndOverrides sets the LaunchTemplateAndOverrides field's value. -func (s *CreateFleetError) SetLaunchTemplateAndOverrides(v *LaunchTemplateAndOverridesResponse) *CreateFleetError { - s.LaunchTemplateAndOverrides = v - return s -} - -// SetLifecycle sets the Lifecycle field's value. -func (s *CreateFleetError) SetLifecycle(v string) *CreateFleetError { - s.Lifecycle = &v - return s -} - type CreateFleetInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -39616,7 +27714,7 @@ type CreateFleetInput struct { // LaunchTemplateConfigs is a required field LaunchTemplateConfigs []*FleetLaunchTemplateConfigRequest `locationNameList:"item" type:"list" required:"true"` - // Describes the configuration of On-Demand Instances in an EC2 Fleet. + // The allocation strategy of On-Demand Instances in an EC2 Fleet. OnDemandOptions *OnDemandOptionsRequest `type:"structure"` // Indicates whether EC2 Fleet should replace unhealthy instances. @@ -39627,11 +27725,12 @@ type CreateFleetInput struct { // The key-value pair for tagging the EC2 Fleet request on creation. The value // for ResourceType must be fleet, otherwise the fleet request fails. To tag - // instances at launch, specify the tags in the launch template (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-templates.html#create-launch-template). - // For information about tagging after launch, see Tagging Your Resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html#tag-resources). + // instances at launch, specify the tags in the launch template (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-launch-templates.html#create-launch-template). + // For information about tagging after launch, see Tagging Your Resources (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html#tag-resources). TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` - // The number of units to request. + // The TotalTargetCapacity, OnDemandTargetCapacity, SpotTargetCapacity, and + // DefaultCapacityType structure. // // TargetCapacitySpecification is a required field TargetCapacitySpecification *TargetCapacitySpecificationRequest `type:"structure" required:"true"` @@ -39640,14 +27739,14 @@ type CreateFleetInput struct { // expires. TerminateInstancesWithExpiration *bool `type:"boolean"` - // The type of the request. By default, the EC2 Fleet places an asynchronous - // request for your desired capacity, and maintains it by replenishing interrupted - // Spot Instances (maintain). A value of instant places a synchronous one-time - // request, and returns errors for any instances that could not be launched. - // A value of request places an asynchronous one-time request without maintaining - // capacity or submitting requests in alternative capacity pools if capacity - // is unavailable. For more information, see EC2 Fleet Request Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-fleet-configuration-strategies.html#ec2-fleet-request-type) - // in the Amazon Elastic Compute Cloud User Guide. + // The type of request. Indicates whether the EC2 Fleet only requests the target + // capacity, or also attempts to maintain it. If you request a certain target + // capacity, EC2 Fleet only places the required requests. It does not attempt + // to replenish instances if capacity is diminished, and does not submit requests + // in alternative capacity pools if capacity is unavailable. To maintain a certain + // target capacity, EC2 Fleet places the required requests to meet this target + // capacity. It also automatically replenishes any interrupted Spot Instances. + // Default: maintain. Type *string `type:"string" enum:"FleetType"` // The start date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). @@ -39656,7 +27755,7 @@ type CreateFleetInput struct { // The end date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). // At this point, no new EC2 Fleet requests are placed or able to fulfill the - // request. If no value is specified, the request remains until you cancel it. + // request. The default end date is 7 days from the current date. ValidUntil *time.Time `type:"timestamp"` } @@ -39779,82 +27878,11 @@ func (s *CreateFleetInput) SetValidUntil(v time.Time) *CreateFleetInput { return s } -// Describes the instances that were launched by the fleet. -type CreateFleetInstance struct { - _ struct{} `type:"structure"` - - // The IDs of the instances. - InstanceIds []*string `locationName:"instanceIds" locationNameList:"item" type:"list"` - - // The instance type. - InstanceType *string `locationName:"instanceType" type:"string" enum:"InstanceType"` - - // The launch templates and overrides that were used for launching the instances. - // Any parameters that you specify in the Overrides override the same parameters - // in the launch template. - LaunchTemplateAndOverrides *LaunchTemplateAndOverridesResponse `locationName:"launchTemplateAndOverrides" type:"structure"` - - // Indicates if the instance that was launched is a Spot Instance or On-Demand - // Instance. - Lifecycle *string `locationName:"lifecycle" type:"string" enum:"InstanceLifecycle"` - - // The value is Windows for Windows instances; otherwise blank. - Platform *string `locationName:"platform" type:"string" enum:"PlatformValues"` -} - -// String returns the string representation -func (s CreateFleetInstance) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateFleetInstance) GoString() string { - return s.String() -} - -// SetInstanceIds sets the InstanceIds field's value. -func (s *CreateFleetInstance) SetInstanceIds(v []*string) *CreateFleetInstance { - s.InstanceIds = v - return s -} - -// SetInstanceType sets the InstanceType field's value. -func (s *CreateFleetInstance) SetInstanceType(v string) *CreateFleetInstance { - s.InstanceType = &v - return s -} - -// SetLaunchTemplateAndOverrides sets the LaunchTemplateAndOverrides field's value. -func (s *CreateFleetInstance) SetLaunchTemplateAndOverrides(v *LaunchTemplateAndOverridesResponse) *CreateFleetInstance { - s.LaunchTemplateAndOverrides = v - return s -} - -// SetLifecycle sets the Lifecycle field's value. -func (s *CreateFleetInstance) SetLifecycle(v string) *CreateFleetInstance { - s.Lifecycle = &v - return s -} - -// SetPlatform sets the Platform field's value. -func (s *CreateFleetInstance) SetPlatform(v string) *CreateFleetInstance { - s.Platform = &v - return s -} - type CreateFleetOutput struct { _ struct{} `type:"structure"` - // Information about the instances that could not be launched by the fleet. - // Valid only when Type is set to instant. - Errors []*CreateFleetError `locationName:"errorSet" locationNameList:"item" type:"list"` - // The ID of the EC2 Fleet. FleetId *string `locationName:"fleetId" type:"string"` - - // Information about the instances that were launched by the fleet. Valid only - // when Type is set to instant. - Instances []*CreateFleetInstance `locationName:"fleetInstanceSet" locationNameList:"item" type:"list"` } // String returns the string representation @@ -39867,36 +27895,21 @@ func (s CreateFleetOutput) GoString() string { return s.String() } -// SetErrors sets the Errors field's value. -func (s *CreateFleetOutput) SetErrors(v []*CreateFleetError) *CreateFleetOutput { - s.Errors = v - return s -} - // SetFleetId sets the FleetId field's value. func (s *CreateFleetOutput) SetFleetId(v string) *CreateFleetOutput { s.FleetId = &v return s } -// SetInstances sets the Instances field's value. -func (s *CreateFleetOutput) SetInstances(v []*CreateFleetInstance) *CreateFleetOutput { - s.Instances = v - return s -} - +// Contains the parameters for CreateFlowLogs. type CreateFlowLogsInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` - // The ARN for the IAM role that permits Amazon EC2 to publish flow logs to - // a CloudWatch Logs log group in your account. - // - // If you specify LogDestinationType as s3, do not specify DeliverLogsPermissionArn - // or LogGroupName. + // The ARN for the IAM role that's used to post flow logs to a log group. DeliverLogsPermissionArn *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -39906,7 +27919,7 @@ type CreateFlowLogsInput struct { DryRun *bool `type:"boolean"` // Specifies the destination to which the flow log data is to be published. - // Flow log data can be published to a CloudWatch Logs log group or an Amazon + // Flow log data can be published to an CloudWatch Logs log group or an Amazon // S3 bucket. The value specified for this parameter depends on the value specified // for LogDestinationType. // @@ -39917,8 +27930,7 @@ type CreateFlowLogsInput struct { // can also specify a subfolder in the bucket. To specify a subfolder in the // bucket, use the following ARN format: bucket_ARN/subfolder_name/. For example, // to specify a subfolder named my-logs in a bucket named my-bucket, use the - // following ARN: arn:aws:s3:::my-bucket/my-logs/. You cannot use AWSLogs as - // a subfolder name. This is a reserved term. + // following ARN: arn:aws:s3:::my-bucket/my-logs/. LogDestination *string `type:"string"` // Specifies the type of destination to which the flow log data is to be published. @@ -39926,35 +27938,25 @@ type CreateFlowLogsInput struct { // flow log data to CloudWatch Logs, specify cloud-watch-logs. To publish flow // log data to Amazon S3, specify s3. // - // If you specify LogDestinationType as s3, do not specify DeliverLogsPermissionArn - // or LogGroupName. - // // Default: cloud-watch-logs LogDestinationType *string `type:"string" enum:"LogDestinationType"` - // The name of a new or existing CloudWatch Logs log group where Amazon EC2 - // publishes your flow logs. - // - // If you specify LogDestinationType as s3, do not specify DeliverLogsPermissionArn - // or LogGroupName. + // The name of the log group. LogGroupName *string `type:"string"` - // The ID of the subnet, network interface, or VPC for which you want to create - // a flow log. + // One or more subnet, network interface, or VPC IDs. // // Constraints: Maximum of 1000 resources // // ResourceIds is a required field ResourceIds []*string `locationName:"ResourceId" locationNameList:"item" type:"list" required:"true"` - // The type of resource for which to create the flow log. For example, if you - // specified a VPC ID for the ResourceId property, specify VPC for this property. + // The type of resource on which to create the flow log. // // ResourceType is a required field ResourceType *string `type:"string" required:"true" enum:"FlowLogsResourceType"` - // The type of traffic to log. You can log traffic that the resource accepts - // or rejects, or all traffic. + // The type of traffic to log. // // TrafficType is a required field TrafficType *string `type:"string" required:"true" enum:"TrafficType"` @@ -40043,6 +28045,7 @@ func (s *CreateFlowLogsInput) SetTrafficType(v string) *CreateFlowLogsInput { return s } +// Contains the output of CreateFlowLogs. type CreateFlowLogsOutput struct { _ struct{} `type:"structure"` @@ -40089,7 +28092,7 @@ type CreateFpgaImageInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). + // of the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // A description for the AFI. @@ -40205,12 +28208,11 @@ func (s *CreateFpgaImageOutput) SetFpgaImageId(v string) *CreateFpgaImageOutput return s } +// Contains the parameters for CreateImage. type CreateImageInput struct { _ struct{} `type:"structure"` - // The block device mappings. This parameter cannot be used to modify the encryption - // status of existing volumes or snapshots. To create an AMI with encrypted - // snapshots, use the CopyImage action. + // Information about one or more block device mappings. BlockDeviceMappings []*BlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"` // A description for the new image. @@ -40305,6 +28307,7 @@ func (s *CreateImageInput) SetNoReboot(v bool) *CreateImageInput { return s } +// Contains the output of CreateImage. type CreateImageOutput struct { _ struct{} `type:"structure"` @@ -40328,6 +28331,7 @@ func (s *CreateImageOutput) SetImageId(v string) *CreateImageOutput { return s } +// Contains the parameters for CreateInstanceExportTask. type CreateInstanceExportTaskInput struct { _ struct{} `type:"structure"` @@ -40394,6 +28398,7 @@ func (s *CreateInstanceExportTaskInput) SetTargetEnvironment(v string) *CreateIn return s } +// Contains the output for CreateInstanceExportTask. type CreateInstanceExportTaskOutput struct { _ struct{} `type:"structure"` @@ -40417,6 +28422,7 @@ func (s *CreateInstanceExportTaskOutput) SetExportTask(v *ExportTask) *CreateIns return s } +// Contains the parameters for CreateInternetGateway. type CreateInternetGatewayInput struct { _ struct{} `type:"structure"` @@ -40443,6 +28449,7 @@ func (s *CreateInternetGatewayInput) SetDryRun(v bool) *CreateInternetGatewayInp return s } +// Contains the output of CreateInternetGateway. type CreateInternetGatewayOutput struct { _ struct{} `type:"structure"` @@ -40466,6 +28473,7 @@ func (s *CreateInternetGatewayOutput) SetInternetGateway(v *InternetGateway) *Cr return s } +// Contains the parameters for CreateKeyPair. type CreateKeyPairInput struct { _ struct{} `type:"structure"` @@ -40564,9 +28572,7 @@ type CreateLaunchTemplateInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - // - // Constraint: Maximum 128 ASCII characters. + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -40680,9 +28686,7 @@ type CreateLaunchTemplateVersionInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - // - // Constraint: Maximum 128 ASCII characters. + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -40809,6 +28813,7 @@ func (s *CreateLaunchTemplateVersionOutput) SetLaunchTemplateVersion(v *LaunchTe return s } +// Contains the parameters for CreateNatGateway. type CreateNatGatewayInput struct { _ struct{} `type:"structure"` @@ -40820,7 +28825,7 @@ type CreateNatGatewayInput struct { AllocationId *string `type:"string" required:"true"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). // // Constraint: Maximum 64 ASCII characters. ClientToken *string `type:"string"` @@ -40875,6 +28880,7 @@ func (s *CreateNatGatewayInput) SetSubnetId(v string) *CreateNatGatewayInput { return s } +// Contains the output of CreateNatGateway. type CreateNatGatewayOutput struct { _ struct{} `type:"structure"` @@ -40908,6 +28914,7 @@ func (s *CreateNatGatewayOutput) SetNatGateway(v *NatGateway) *CreateNatGatewayO return s } +// Contains the parameters for CreateNetworkAclEntry. type CreateNetworkAclEntryInput struct { _ struct{} `type:"structure"` @@ -40926,8 +28933,8 @@ type CreateNetworkAclEntryInput struct { // Egress is a required field Egress *bool `locationName:"egress" type:"boolean" required:"true"` - // ICMP protocol: The ICMP or ICMPv6 type and code. Required if specifying protocol - // 1 (ICMP) or protocol 58 (ICMPv6) with an IPv6 CIDR block. + // ICMP protocol: The ICMP or ICMPv6 type and code. Required if specifying the + // ICMP protocol, or protocol 58 (ICMPv6) with an IPv6 CIDR block. IcmpTypeCode *IcmpTypeCode `locationName:"Icmp" type:"structure"` // The IPv6 network range to allow or deny, in CIDR notation (for example 2001:db8:1234:1a00::/64). @@ -40938,17 +28945,16 @@ type CreateNetworkAclEntryInput struct { // NetworkAclId is a required field NetworkAclId *string `locationName:"networkAclId" type:"string" required:"true"` - // TCP or UDP protocols: The range of ports the rule applies to. Required if - // specifying protocol 6 (TCP) or 17 (UDP). + // TCP or UDP protocols: The range of ports the rule applies to. PortRange *PortRange `locationName:"portRange" type:"structure"` - // The protocol number. A value of "-1" means all protocols. If you specify - // "-1" or a protocol number other than "6" (TCP), "17" (UDP), or "1" (ICMP), - // traffic on all ports is allowed, regardless of any ports or ICMP types or - // codes that you specify. If you specify protocol "58" (ICMPv6) and specify - // an IPv4 CIDR block, traffic for all ICMP types and codes allowed, regardless - // of any that you specify. If you specify protocol "58" (ICMPv6) and specify - // an IPv6 CIDR block, you must specify an ICMP type and code. + // The protocol. A value of -1 or all means all protocols. If you specify all, + // -1, or a protocol number other than 6 (tcp), 17 (udp), or 1 (icmp), traffic + // on all ports is allowed, regardless of any ports or ICMP types or codes that + // you specify. If you specify protocol 58 (ICMPv6) and specify an IPv4 CIDR + // block, traffic for all ICMP types and codes allowed, regardless of any that + // you specify. If you specify protocol 58 (ICMPv6) and specify an IPv6 CIDR + // block, you must specify an ICMP type and code. // // Protocol is a required field Protocol *string `locationName:"protocol" type:"string" required:"true"` @@ -41077,6 +29083,7 @@ func (s CreateNetworkAclEntryOutput) GoString() string { return s.String() } +// Contains the parameters for CreateNetworkAcl. type CreateNetworkAclInput struct { _ struct{} `type:"structure"` @@ -41127,6 +29134,7 @@ func (s *CreateNetworkAclInput) SetVpcId(v string) *CreateNetworkAclInput { return s } +// Contains the output of CreateNetworkAcl. type CreateNetworkAclOutput struct { _ struct{} `type:"structure"` @@ -41166,11 +29174,6 @@ type CreateNetworkInterfaceInput struct { // The IDs of one or more security groups. Groups []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` - // Indicates the type of network interface. To create an Elastic Fabric Adapter - // (EFA), specify efa. For more information, see Elastic Fabric Adapter (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/efa.html) - // in the Amazon Elastic Compute Cloud User Guide. - InterfaceType *string `type:"string" enum:"NetworkInterfaceCreationType"` - // The number of IPv6 addresses to assign to a network interface. Amazon EC2 // automatically selects the IPv6 addresses from the subnet range. You can't // use this option if specifying specific IPv6 addresses. If your subnet has @@ -41199,7 +29202,7 @@ type CreateNetworkInterfaceInput struct { // // The number of IP addresses you can assign to a network interface varies by // instance type. For more information, see IP Addresses Per ENI Per Instance - // Type (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#AvailableIpPerENI) + // Type (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#AvailableIpPerENI) // in the Amazon Virtual Private Cloud User Guide. SecondaryPrivateIpAddressCount *int64 `locationName:"secondaryPrivateIpAddressCount" type:"integer"` @@ -41250,12 +29253,6 @@ func (s *CreateNetworkInterfaceInput) SetGroups(v []*string) *CreateNetworkInter return s } -// SetInterfaceType sets the InterfaceType field's value. -func (s *CreateNetworkInterfaceInput) SetInterfaceType(v string) *CreateNetworkInterfaceInput { - s.InterfaceType = &v - return s -} - // SetIpv6AddressCount sets the Ipv6AddressCount field's value. func (s *CreateNetworkInterfaceInput) SetIpv6AddressCount(v int64) *CreateNetworkInterfaceInput { s.Ipv6AddressCount = &v @@ -41423,6 +29420,7 @@ func (s *CreateNetworkInterfacePermissionOutput) SetInterfacePermission(v *Netwo return s } +// Contains the parameters for CreatePlacementGroup. type CreatePlacementGroupInput struct { _ struct{} `type:"structure"` @@ -41433,16 +29431,17 @@ type CreatePlacementGroupInput struct { DryRun *bool `locationName:"dryRun" type:"boolean"` // A name for the placement group. Must be unique within the scope of your account - // for the Region. + // for the region. // // Constraints: Up to 255 ASCII characters - GroupName *string `locationName:"groupName" type:"string"` - - // The number of partitions. Valid only when Strategy is set to partition. - PartitionCount *int64 `type:"integer"` + // + // GroupName is a required field + GroupName *string `locationName:"groupName" type:"string" required:"true"` // The placement strategy. - Strategy *string `locationName:"strategy" type:"string" enum:"PlacementStrategy"` + // + // Strategy is a required field + Strategy *string `locationName:"strategy" type:"string" required:"true" enum:"PlacementStrategy"` } // String returns the string representation @@ -41455,6 +29454,22 @@ func (s CreatePlacementGroupInput) GoString() string { return s.String() } +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePlacementGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePlacementGroupInput"} + if s.GroupName == nil { + invalidParams.Add(request.NewErrParamRequired("GroupName")) + } + if s.Strategy == nil { + invalidParams.Add(request.NewErrParamRequired("Strategy")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + // SetDryRun sets the DryRun field's value. func (s *CreatePlacementGroupInput) SetDryRun(v bool) *CreatePlacementGroupInput { s.DryRun = &v @@ -41467,12 +29482,6 @@ func (s *CreatePlacementGroupInput) SetGroupName(v string) *CreatePlacementGroup return s } -// SetPartitionCount sets the PartitionCount field's value. -func (s *CreatePlacementGroupInput) SetPartitionCount(v int64) *CreatePlacementGroupInput { - s.PartitionCount = &v - return s -} - // SetStrategy sets the Strategy field's value. func (s *CreatePlacementGroupInput) SetStrategy(v string) *CreatePlacementGroupInput { s.Strategy = &v @@ -41499,7 +29508,7 @@ type CreateReservedInstancesListingInput struct { // Unique, case-sensitive identifier you provide to ensure idempotency of your // listings. This helps avoid duplicate listings. For more information, see - // Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). // // ClientToken is a required field ClientToken *string `locationName:"clientToken" type:"string" required:"true"` @@ -41604,6 +29613,7 @@ func (s *CreateReservedInstancesListingOutput) SetReservedInstancesListings(v [] return s } +// Contains the parameters for CreateRoute. type CreateRouteInput struct { _ struct{} `type:"structure"` @@ -41643,9 +29653,6 @@ type CreateRouteInput struct { // RouteTableId is a required field RouteTableId *string `locationName:"routeTableId" type:"string" required:"true"` - // The ID of a transit gateway. - TransitGatewayId *string `type:"string"` - // The ID of a VPC peering connection. VpcPeeringConnectionId *string `locationName:"vpcPeeringConnectionId" type:"string"` } @@ -41727,18 +29734,13 @@ func (s *CreateRouteInput) SetRouteTableId(v string) *CreateRouteInput { return s } -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *CreateRouteInput) SetTransitGatewayId(v string) *CreateRouteInput { - s.TransitGatewayId = &v - return s -} - // SetVpcPeeringConnectionId sets the VpcPeeringConnectionId field's value. func (s *CreateRouteInput) SetVpcPeeringConnectionId(v string) *CreateRouteInput { s.VpcPeeringConnectionId = &v return s } +// Contains the output of CreateRoute. type CreateRouteOutput struct { _ struct{} `type:"structure"` @@ -41762,6 +29764,7 @@ func (s *CreateRouteOutput) SetReturn(v bool) *CreateRouteOutput { return s } +// Contains the parameters for CreateRouteTable. type CreateRouteTableInput struct { _ struct{} `type:"structure"` @@ -41812,6 +29815,7 @@ func (s *CreateRouteTableInput) SetVpcId(v string) *CreateRouteTableInput { return s } +// Contains the output of CreateRouteTable. type CreateRouteTableOutput struct { _ struct{} `type:"structure"` @@ -41835,6 +29839,7 @@ func (s *CreateRouteTableOutput) SetRouteTable(v *RouteTable) *CreateRouteTableO return s } +// Contains the parameters for CreateSecurityGroup. type CreateSecurityGroupInput struct { _ struct{} `type:"structure"` @@ -41920,6 +29925,7 @@ func (s *CreateSecurityGroupInput) SetVpcId(v string) *CreateSecurityGroupInput return s } +// Contains the output of CreateSecurityGroup. type CreateSecurityGroupOutput struct { _ struct{} `type:"structure"` @@ -42012,105 +30018,6 @@ func (s *CreateSnapshotInput) SetVolumeId(v string) *CreateSnapshotInput { return s } -type CreateSnapshotsInput struct { - _ struct{} `type:"structure"` - - // Copies the tags from the specified instance to all snapshots. - CopyTagsFromSource *string `type:"string" enum:"CopyTagsFromSource"` - - // A description propagated to every snapshot specified by the instance. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action without actually - // making the request. Provides an error response. If you have the required - // permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The instance to specify which volumes should be included in the snapshots. - // - // InstanceSpecification is a required field - InstanceSpecification *InstanceSpecification `type:"structure" required:"true"` - - // Tags to apply to every snapshot specified by the instance. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s CreateSnapshotsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateSnapshotsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateSnapshotsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateSnapshotsInput"} - if s.InstanceSpecification == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceSpecification")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCopyTagsFromSource sets the CopyTagsFromSource field's value. -func (s *CreateSnapshotsInput) SetCopyTagsFromSource(v string) *CreateSnapshotsInput { - s.CopyTagsFromSource = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateSnapshotsInput) SetDescription(v string) *CreateSnapshotsInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateSnapshotsInput) SetDryRun(v bool) *CreateSnapshotsInput { - s.DryRun = &v - return s -} - -// SetInstanceSpecification sets the InstanceSpecification field's value. -func (s *CreateSnapshotsInput) SetInstanceSpecification(v *InstanceSpecification) *CreateSnapshotsInput { - s.InstanceSpecification = v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateSnapshotsInput) SetTagSpecifications(v []*TagSpecification) *CreateSnapshotsInput { - s.TagSpecifications = v - return s -} - -type CreateSnapshotsOutput struct { - _ struct{} `type:"structure"` - - // List of snapshots. - Snapshots []*SnapshotInfo `locationName:"snapshotSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s CreateSnapshotsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateSnapshotsOutput) GoString() string { - return s.String() -} - -// SetSnapshots sets the Snapshots field's value. -func (s *CreateSnapshotsOutput) SetSnapshots(v []*SnapshotInfo) *CreateSnapshotsOutput { - s.Snapshots = v - return s -} - // Contains the parameters for CreateSpotDatafeedSubscription. type CreateSpotDatafeedSubscriptionInput struct { _ struct{} `type:"structure"` @@ -42195,6 +30102,7 @@ func (s *CreateSpotDatafeedSubscriptionOutput) SetSpotDatafeedSubscription(v *Sp return s } +// Contains the parameters for CreateSubnet. type CreateSubnetInput struct { _ struct{} `type:"structure"` @@ -42204,9 +30112,6 @@ type CreateSubnetInput struct { // VPC, we may not necessarily select a different zone for each subnet. AvailabilityZone *string `type:"string"` - // The AZ ID of the subnet. - AvailabilityZoneId *string `type:"string"` - // The IPv4 network range for the subnet, in CIDR notation. For example, 10.0.0.0/24. // // CidrBlock is a required field @@ -42260,12 +30165,6 @@ func (s *CreateSubnetInput) SetAvailabilityZone(v string) *CreateSubnetInput { return s } -// SetAvailabilityZoneId sets the AvailabilityZoneId field's value. -func (s *CreateSubnetInput) SetAvailabilityZoneId(v string) *CreateSubnetInput { - s.AvailabilityZoneId = &v - return s -} - // SetCidrBlock sets the CidrBlock field's value. func (s *CreateSubnetInput) SetCidrBlock(v string) *CreateSubnetInput { s.CidrBlock = &v @@ -42290,6 +30189,7 @@ func (s *CreateSubnetInput) SetVpcId(v string) *CreateSubnetInput { return s } +// Contains the output of CreateSubnet. type CreateSubnetOutput struct { _ struct{} `type:"structure"` @@ -42313,6 +30213,7 @@ func (s *CreateSubnetOutput) SetSubnet(v *Subnet) *CreateSubnetOutput { return s } +// Contains the parameters for CreateTags. type CreateTagsInput struct { _ struct{} `type:"structure"` @@ -42322,17 +30223,14 @@ type CreateTagsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the resources, separated by spaces. - // - // Constraints: Up to 1000 resource IDs. We recommend breaking up this request - // into smaller batches. + // The IDs of one or more resources to tag. For example, ami-1a2b3c4d. // // Resources is a required field Resources []*string `locationName:"ResourceId" type:"list" required:"true"` - // The tags. The value parameter is required, but if you don't want the tag - // to have a value, specify the parameter with no value, and we set the value - // to an empty string. + // One or more tags. The value parameter is required, but if you don't want + // the tag to have a value, specify the parameter with no value, and we set + // the value to an empty string. // // Tags is a required field Tags []*Tag `locationName:"Tag" locationNameList:"item" type:"list" required:"true"` @@ -42396,1013 +30294,12 @@ func (s CreateTagsOutput) GoString() string { return s.String() } -type CreateTrafficMirrorFilterInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The description of the Traffic Mirror filter. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The tags to assign to a Traffic Mirror filter. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s CreateTrafficMirrorFilterInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorFilterInput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorFilterInput) SetClientToken(v string) *CreateTrafficMirrorFilterInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateTrafficMirrorFilterInput) SetDescription(v string) *CreateTrafficMirrorFilterInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTrafficMirrorFilterInput) SetDryRun(v bool) *CreateTrafficMirrorFilterInput { - s.DryRun = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTrafficMirrorFilterInput) SetTagSpecifications(v []*TagSpecification) *CreateTrafficMirrorFilterInput { - s.TagSpecifications = v - return s -} - -type CreateTrafficMirrorFilterOutput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" type:"string"` - - // Information about the Traffic Mirror filter. - TrafficMirrorFilter *TrafficMirrorFilter `locationName:"trafficMirrorFilter" type:"structure"` -} - -// String returns the string representation -func (s CreateTrafficMirrorFilterOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorFilterOutput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorFilterOutput) SetClientToken(v string) *CreateTrafficMirrorFilterOutput { - s.ClientToken = &v - return s -} - -// SetTrafficMirrorFilter sets the TrafficMirrorFilter field's value. -func (s *CreateTrafficMirrorFilterOutput) SetTrafficMirrorFilter(v *TrafficMirrorFilter) *CreateTrafficMirrorFilterOutput { - s.TrafficMirrorFilter = v - return s -} - -type CreateTrafficMirrorFilterRuleInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The description of the Traffic Mirror rule. - Description *string `type:"string"` - - // The destination CIDR block to assign to the Traffic Mirror rule. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // The destination port range. - DestinationPortRange *TrafficMirrorPortRangeRequest `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The protocol, for example UDP, to assign to the Traffic Mirror rule. - // - // For information about the protocol value, see Protocol Numbers (https://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml) - // on the Internet Assigned Numbers Authority (IANA) website. - Protocol *int64 `type:"integer"` - - // The action to take (accept | reject) on the filtered traffic. - // - // RuleAction is a required field - RuleAction *string `type:"string" required:"true" enum:"TrafficMirrorRuleAction"` - - // The number of the Traffic Mirror rule. This number must be unique for each - // Traffic Mirror rule in a given direction. The rules are processed in ascending - // order by rule number. - // - // RuleNumber is a required field - RuleNumber *int64 `type:"integer" required:"true"` - - // The source CIDR block to assign to the Traffic Mirror rule. - // - // SourceCidrBlock is a required field - SourceCidrBlock *string `type:"string" required:"true"` - - // The source port range. - SourcePortRange *TrafficMirrorPortRangeRequest `type:"structure"` - - // The type of traffic (ingress | egress). - // - // TrafficDirection is a required field - TrafficDirection *string `type:"string" required:"true" enum:"TrafficDirection"` - - // The ID of the filter that this rule is associated with. - // - // TrafficMirrorFilterId is a required field - TrafficMirrorFilterId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateTrafficMirrorFilterRuleInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorFilterRuleInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateTrafficMirrorFilterRuleInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateTrafficMirrorFilterRuleInput"} - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - if s.RuleAction == nil { - invalidParams.Add(request.NewErrParamRequired("RuleAction")) - } - if s.RuleNumber == nil { - invalidParams.Add(request.NewErrParamRequired("RuleNumber")) - } - if s.SourceCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("SourceCidrBlock")) - } - if s.TrafficDirection == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficDirection")) - } - if s.TrafficMirrorFilterId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetClientToken(v string) *CreateTrafficMirrorFilterRuleInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetDescription(v string) *CreateTrafficMirrorFilterRuleInput { - s.Description = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetDestinationCidrBlock(v string) *CreateTrafficMirrorFilterRuleInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDestinationPortRange sets the DestinationPortRange field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetDestinationPortRange(v *TrafficMirrorPortRangeRequest) *CreateTrafficMirrorFilterRuleInput { - s.DestinationPortRange = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetDryRun(v bool) *CreateTrafficMirrorFilterRuleInput { - s.DryRun = &v - return s -} - -// SetProtocol sets the Protocol field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetProtocol(v int64) *CreateTrafficMirrorFilterRuleInput { - s.Protocol = &v - return s -} - -// SetRuleAction sets the RuleAction field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetRuleAction(v string) *CreateTrafficMirrorFilterRuleInput { - s.RuleAction = &v - return s -} - -// SetRuleNumber sets the RuleNumber field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetRuleNumber(v int64) *CreateTrafficMirrorFilterRuleInput { - s.RuleNumber = &v - return s -} - -// SetSourceCidrBlock sets the SourceCidrBlock field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetSourceCidrBlock(v string) *CreateTrafficMirrorFilterRuleInput { - s.SourceCidrBlock = &v - return s -} - -// SetSourcePortRange sets the SourcePortRange field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetSourcePortRange(v *TrafficMirrorPortRangeRequest) *CreateTrafficMirrorFilterRuleInput { - s.SourcePortRange = v - return s -} - -// SetTrafficDirection sets the TrafficDirection field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetTrafficDirection(v string) *CreateTrafficMirrorFilterRuleInput { - s.TrafficDirection = &v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *CreateTrafficMirrorFilterRuleInput) SetTrafficMirrorFilterId(v string) *CreateTrafficMirrorFilterRuleInput { - s.TrafficMirrorFilterId = &v - return s -} - -type CreateTrafficMirrorFilterRuleOutput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" type:"string"` - - // The Traffic Mirror rule. - TrafficMirrorFilterRule *TrafficMirrorFilterRule `locationName:"trafficMirrorFilterRule" type:"structure"` -} - -// String returns the string representation -func (s CreateTrafficMirrorFilterRuleOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorFilterRuleOutput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorFilterRuleOutput) SetClientToken(v string) *CreateTrafficMirrorFilterRuleOutput { - s.ClientToken = &v - return s -} - -// SetTrafficMirrorFilterRule sets the TrafficMirrorFilterRule field's value. -func (s *CreateTrafficMirrorFilterRuleOutput) SetTrafficMirrorFilterRule(v *TrafficMirrorFilterRule) *CreateTrafficMirrorFilterRuleOutput { - s.TrafficMirrorFilterRule = v - return s -} - -type CreateTrafficMirrorSessionInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The description of the Traffic Mirror session. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the source network interface. - // - // NetworkInterfaceId is a required field - NetworkInterfaceId *string `type:"string" required:"true"` - - // The number of bytes in each packet to mirror. These are bytes after the VXLAN - // header. Do not specify this parameter when you want to mirror the entire - // packet. To mirror a subset of the packet, set this to the length (in bytes) - // that you want to mirror. For example, if you set this value to 1network0, - // then the first 100 bytes that meet the filter criteria are copied to the - // target. - // - // If you do not want to mirror the entire packet, use the PacketLength parameter - // to specify the number of bytes in each packet to mirror. - PacketLength *int64 `type:"integer"` - - // The session number determines the order in which sessions are evaluated when - // an interface is used by multiple sessions. The first session with a matching - // filter is the one that mirrors the packets. - // - // Valid values are 1-32766. - // - // SessionNumber is a required field - SessionNumber *int64 `type:"integer" required:"true"` - - // The tags to assign to a Traffic Mirror session. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` - - // The ID of the Traffic Mirror filter. - // - // TrafficMirrorFilterId is a required field - TrafficMirrorFilterId *string `type:"string" required:"true"` - - // The ID of the Traffic Mirror target. - // - // TrafficMirrorTargetId is a required field - TrafficMirrorTargetId *string `type:"string" required:"true"` - - // The VXLAN ID for the Traffic Mirror session. For more information about the - // VXLAN protocol, see RFC 7348 (https://tools.ietf.org/html/rfc7348). If you - // do not specify a VirtualNetworkId, an account-wide unique id is chosen at - // random. - VirtualNetworkId *int64 `type:"integer"` -} - -// String returns the string representation -func (s CreateTrafficMirrorSessionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorSessionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateTrafficMirrorSessionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateTrafficMirrorSessionInput"} - if s.NetworkInterfaceId == nil { - invalidParams.Add(request.NewErrParamRequired("NetworkInterfaceId")) - } - if s.SessionNumber == nil { - invalidParams.Add(request.NewErrParamRequired("SessionNumber")) - } - if s.TrafficMirrorFilterId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterId")) - } - if s.TrafficMirrorTargetId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorTargetId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorSessionInput) SetClientToken(v string) *CreateTrafficMirrorSessionInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateTrafficMirrorSessionInput) SetDescription(v string) *CreateTrafficMirrorSessionInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTrafficMirrorSessionInput) SetDryRun(v bool) *CreateTrafficMirrorSessionInput { - s.DryRun = &v - return s -} - -// SetNetworkInterfaceId sets the NetworkInterfaceId field's value. -func (s *CreateTrafficMirrorSessionInput) SetNetworkInterfaceId(v string) *CreateTrafficMirrorSessionInput { - s.NetworkInterfaceId = &v - return s -} - -// SetPacketLength sets the PacketLength field's value. -func (s *CreateTrafficMirrorSessionInput) SetPacketLength(v int64) *CreateTrafficMirrorSessionInput { - s.PacketLength = &v - return s -} - -// SetSessionNumber sets the SessionNumber field's value. -func (s *CreateTrafficMirrorSessionInput) SetSessionNumber(v int64) *CreateTrafficMirrorSessionInput { - s.SessionNumber = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTrafficMirrorSessionInput) SetTagSpecifications(v []*TagSpecification) *CreateTrafficMirrorSessionInput { - s.TagSpecifications = v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *CreateTrafficMirrorSessionInput) SetTrafficMirrorFilterId(v string) *CreateTrafficMirrorSessionInput { - s.TrafficMirrorFilterId = &v - return s -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *CreateTrafficMirrorSessionInput) SetTrafficMirrorTargetId(v string) *CreateTrafficMirrorSessionInput { - s.TrafficMirrorTargetId = &v - return s -} - -// SetVirtualNetworkId sets the VirtualNetworkId field's value. -func (s *CreateTrafficMirrorSessionInput) SetVirtualNetworkId(v int64) *CreateTrafficMirrorSessionInput { - s.VirtualNetworkId = &v - return s -} - -type CreateTrafficMirrorSessionOutput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" type:"string"` - - // Information about the Traffic Mirror session. - TrafficMirrorSession *TrafficMirrorSession `locationName:"trafficMirrorSession" type:"structure"` -} - -// String returns the string representation -func (s CreateTrafficMirrorSessionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorSessionOutput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorSessionOutput) SetClientToken(v string) *CreateTrafficMirrorSessionOutput { - s.ClientToken = &v - return s -} - -// SetTrafficMirrorSession sets the TrafficMirrorSession field's value. -func (s *CreateTrafficMirrorSessionOutput) SetTrafficMirrorSession(v *TrafficMirrorSession) *CreateTrafficMirrorSessionOutput { - s.TrafficMirrorSession = v - return s -} - -type CreateTrafficMirrorTargetInput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `type:"string" idempotencyToken:"true"` - - // The description of the Traffic Mirror target. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The network interface ID that is associated with the target. - NetworkInterfaceId *string `type:"string"` - - // The Amazon Resource Name (ARN) of the Network Load Balancer that is associated - // with the target. - NetworkLoadBalancerArn *string `type:"string"` - - // The tags to assign to the Traffic Mirror target. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s CreateTrafficMirrorTargetInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorTargetInput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorTargetInput) SetClientToken(v string) *CreateTrafficMirrorTargetInput { - s.ClientToken = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *CreateTrafficMirrorTargetInput) SetDescription(v string) *CreateTrafficMirrorTargetInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTrafficMirrorTargetInput) SetDryRun(v bool) *CreateTrafficMirrorTargetInput { - s.DryRun = &v - return s -} - -// SetNetworkInterfaceId sets the NetworkInterfaceId field's value. -func (s *CreateTrafficMirrorTargetInput) SetNetworkInterfaceId(v string) *CreateTrafficMirrorTargetInput { - s.NetworkInterfaceId = &v - return s -} - -// SetNetworkLoadBalancerArn sets the NetworkLoadBalancerArn field's value. -func (s *CreateTrafficMirrorTargetInput) SetNetworkLoadBalancerArn(v string) *CreateTrafficMirrorTargetInput { - s.NetworkLoadBalancerArn = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTrafficMirrorTargetInput) SetTagSpecifications(v []*TagSpecification) *CreateTrafficMirrorTargetInput { - s.TagSpecifications = v - return s -} - -type CreateTrafficMirrorTargetOutput struct { - _ struct{} `type:"structure"` - - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - ClientToken *string `locationName:"clientToken" type:"string"` - - // Information about the Traffic Mirror target. - TrafficMirrorTarget *TrafficMirrorTarget `locationName:"trafficMirrorTarget" type:"structure"` -} - -// String returns the string representation -func (s CreateTrafficMirrorTargetOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTrafficMirrorTargetOutput) GoString() string { - return s.String() -} - -// SetClientToken sets the ClientToken field's value. -func (s *CreateTrafficMirrorTargetOutput) SetClientToken(v string) *CreateTrafficMirrorTargetOutput { - s.ClientToken = &v - return s -} - -// SetTrafficMirrorTarget sets the TrafficMirrorTarget field's value. -func (s *CreateTrafficMirrorTargetOutput) SetTrafficMirrorTarget(v *TrafficMirrorTarget) *CreateTrafficMirrorTargetOutput { - s.TrafficMirrorTarget = v - return s -} - -type CreateTransitGatewayInput struct { - _ struct{} `type:"structure"` - - // A description of the transit gateway. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The transit gateway options. - Options *TransitGatewayRequestOptions `type:"structure"` - - // The tags to apply to the transit gateway. - TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s CreateTransitGatewayInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayInput) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *CreateTransitGatewayInput) SetDescription(v string) *CreateTransitGatewayInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTransitGatewayInput) SetDryRun(v bool) *CreateTransitGatewayInput { - s.DryRun = &v - return s -} - -// SetOptions sets the Options field's value. -func (s *CreateTransitGatewayInput) SetOptions(v *TransitGatewayRequestOptions) *CreateTransitGatewayInput { - s.Options = v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTransitGatewayInput) SetTagSpecifications(v []*TagSpecification) *CreateTransitGatewayInput { - s.TagSpecifications = v - return s -} - -type CreateTransitGatewayOutput struct { - _ struct{} `type:"structure"` - - // Information about the transit gateway. - TransitGateway *TransitGateway `locationName:"transitGateway" type:"structure"` -} - -// String returns the string representation -func (s CreateTransitGatewayOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayOutput) GoString() string { - return s.String() -} - -// SetTransitGateway sets the TransitGateway field's value. -func (s *CreateTransitGatewayOutput) SetTransitGateway(v *TransitGateway) *CreateTransitGatewayOutput { - s.TransitGateway = v - return s -} - -type CreateTransitGatewayRouteInput struct { - _ struct{} `type:"structure"` - - // Indicates whether to drop traffic that matches this route. - Blackhole *bool `type:"boolean"` - - // The CIDR range used for destination matches. Routing decisions are based - // on the most specific match. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `type:"string"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateTransitGatewayRouteInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayRouteInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateTransitGatewayRouteInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateTransitGatewayRouteInput"} - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetBlackhole sets the Blackhole field's value. -func (s *CreateTransitGatewayRouteInput) SetBlackhole(v bool) *CreateTransitGatewayRouteInput { - s.Blackhole = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *CreateTransitGatewayRouteInput) SetDestinationCidrBlock(v string) *CreateTransitGatewayRouteInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTransitGatewayRouteInput) SetDryRun(v bool) *CreateTransitGatewayRouteInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *CreateTransitGatewayRouteInput) SetTransitGatewayAttachmentId(v string) *CreateTransitGatewayRouteInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *CreateTransitGatewayRouteInput) SetTransitGatewayRouteTableId(v string) *CreateTransitGatewayRouteInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type CreateTransitGatewayRouteOutput struct { - _ struct{} `type:"structure"` - - // Information about the route. - Route *TransitGatewayRoute `locationName:"route" type:"structure"` -} - -// String returns the string representation -func (s CreateTransitGatewayRouteOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayRouteOutput) GoString() string { - return s.String() -} - -// SetRoute sets the Route field's value. -func (s *CreateTransitGatewayRouteOutput) SetRoute(v *TransitGatewayRoute) *CreateTransitGatewayRouteOutput { - s.Route = v - return s -} - -type CreateTransitGatewayRouteTableInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The tags to apply to the transit gateway route table. - TagSpecifications []*TagSpecification `locationNameList:"item" type:"list"` - - // The ID of the transit gateway. - // - // TransitGatewayId is a required field - TransitGatewayId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateTransitGatewayRouteTableInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayRouteTableInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateTransitGatewayRouteTableInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateTransitGatewayRouteTableInput"} - if s.TransitGatewayId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTransitGatewayRouteTableInput) SetDryRun(v bool) *CreateTransitGatewayRouteTableInput { - s.DryRun = &v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTransitGatewayRouteTableInput) SetTagSpecifications(v []*TagSpecification) *CreateTransitGatewayRouteTableInput { - s.TagSpecifications = v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *CreateTransitGatewayRouteTableInput) SetTransitGatewayId(v string) *CreateTransitGatewayRouteTableInput { - s.TransitGatewayId = &v - return s -} - -type CreateTransitGatewayRouteTableOutput struct { - _ struct{} `type:"structure"` - - // Information about the transit gateway route table. - TransitGatewayRouteTable *TransitGatewayRouteTable `locationName:"transitGatewayRouteTable" type:"structure"` -} - -// String returns the string representation -func (s CreateTransitGatewayRouteTableOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayRouteTableOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayRouteTable sets the TransitGatewayRouteTable field's value. -func (s *CreateTransitGatewayRouteTableOutput) SetTransitGatewayRouteTable(v *TransitGatewayRouteTable) *CreateTransitGatewayRouteTableOutput { - s.TransitGatewayRouteTable = v - return s -} - -type CreateTransitGatewayVpcAttachmentInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The VPC attachment options. - Options *CreateTransitGatewayVpcAttachmentRequestOptions `type:"structure"` - - // The IDs of one or more subnets. You can specify only one subnet per Availability - // Zone. You must specify at least one subnet, but we recommend that you specify - // two subnets for better availability. The transit gateway uses one IP address - // from each specified subnet. - // - // SubnetIds is a required field - SubnetIds []*string `locationNameList:"item" type:"list" required:"true"` - - // The tags to apply to the VPC attachment. - TagSpecifications []*TagSpecification `locationNameList:"item" type:"list"` - - // The ID of the transit gateway. - // - // TransitGatewayId is a required field - TransitGatewayId *string `type:"string" required:"true"` - - // The ID of the VPC. - // - // VpcId is a required field - VpcId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s CreateTransitGatewayVpcAttachmentInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayVpcAttachmentInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *CreateTransitGatewayVpcAttachmentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateTransitGatewayVpcAttachmentInput"} - if s.SubnetIds == nil { - invalidParams.Add(request.NewErrParamRequired("SubnetIds")) - } - if s.TransitGatewayId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayId")) - } - if s.VpcId == nil { - invalidParams.Add(request.NewErrParamRequired("VpcId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetDryRun(v bool) *CreateTransitGatewayVpcAttachmentInput { - s.DryRun = &v - return s -} - -// SetOptions sets the Options field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetOptions(v *CreateTransitGatewayVpcAttachmentRequestOptions) *CreateTransitGatewayVpcAttachmentInput { - s.Options = v - return s -} - -// SetSubnetIds sets the SubnetIds field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetSubnetIds(v []*string) *CreateTransitGatewayVpcAttachmentInput { - s.SubnetIds = v - return s -} - -// SetTagSpecifications sets the TagSpecifications field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetTagSpecifications(v []*TagSpecification) *CreateTransitGatewayVpcAttachmentInput { - s.TagSpecifications = v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetTransitGatewayId(v string) *CreateTransitGatewayVpcAttachmentInput { - s.TransitGatewayId = &v - return s -} - -// SetVpcId sets the VpcId field's value. -func (s *CreateTransitGatewayVpcAttachmentInput) SetVpcId(v string) *CreateTransitGatewayVpcAttachmentInput { - s.VpcId = &v - return s -} - -type CreateTransitGatewayVpcAttachmentOutput struct { - _ struct{} `type:"structure"` - - // Information about the VPC attachment. - TransitGatewayVpcAttachment *TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachment" type:"structure"` -} - -// String returns the string representation -func (s CreateTransitGatewayVpcAttachmentOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayVpcAttachmentOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayVpcAttachment sets the TransitGatewayVpcAttachment field's value. -func (s *CreateTransitGatewayVpcAttachmentOutput) SetTransitGatewayVpcAttachment(v *TransitGatewayVpcAttachment) *CreateTransitGatewayVpcAttachmentOutput { - s.TransitGatewayVpcAttachment = v - return s -} - -// Describes the options for a VPC attachment. -type CreateTransitGatewayVpcAttachmentRequestOptions struct { - _ struct{} `type:"structure"` - - // Enable or disable DNS support. The default is enable. - DnsSupport *string `type:"string" enum:"DnsSupportValue"` - - // Enable or disable IPv6 support. The default is enable. - Ipv6Support *string `type:"string" enum:"Ipv6SupportValue"` -} - -// String returns the string representation -func (s CreateTransitGatewayVpcAttachmentRequestOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s CreateTransitGatewayVpcAttachmentRequestOptions) GoString() string { - return s.String() -} - -// SetDnsSupport sets the DnsSupport field's value. -func (s *CreateTransitGatewayVpcAttachmentRequestOptions) SetDnsSupport(v string) *CreateTransitGatewayVpcAttachmentRequestOptions { - s.DnsSupport = &v - return s -} - -// SetIpv6Support sets the Ipv6Support field's value. -func (s *CreateTransitGatewayVpcAttachmentRequestOptions) SetIpv6Support(v string) *CreateTransitGatewayVpcAttachmentRequestOptions { - s.Ipv6Support = &v - return s -} - // Contains the parameters for CreateVolume. type CreateVolumeInput struct { _ struct{} `type:"structure"` - // The Availability Zone in which to create the volume. + // The Availability Zone in which to create the volume. Use DescribeAvailabilityZones + // to list the Availability Zones that are currently available to you. // // AvailabilityZone is a required field AvailabilityZone *string `type:"string" required:"true"` @@ -43413,62 +30310,61 @@ type CreateVolumeInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // Specifies whether the volume should be encrypted. The effect of setting the - // encryption state to true depends on the volume origin (new or from a snapshot), - // starting encryption state, ownership, and whether encryption by default is - // enabled. For more information, see Encryption by Default (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#encryption-by-default) + // Specifies whether the volume should be encrypted. Encrypted Amazon EBS volumes + // may only be attached to instances that support Amazon EBS encryption. Volumes + // that are created from encrypted snapshots are automatically encrypted. There + // is no way to create an encrypted volume from an unencrypted snapshot or vice + // versa. If your AMI uses encrypted volumes, you can only launch it on supported + // instance types. For more information, see Amazon EBS Encryption (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) // in the Amazon Elastic Compute Cloud User Guide. - // - // Encrypted Amazon EBS volumes must be attached to instances that support Amazon - // EBS encryption. For more information, see Supported Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#EBSEncryption_supported_instances). Encrypted *bool `locationName:"encrypted" type:"boolean"` // The number of I/O operations per second (IOPS) to provision for the volume, - // with a maximum ratio of 50 IOPS/GiB. Range is 100 to 64,000 IOPS for volumes - // in most Regions. Maximum IOPS of 64,000 is guaranteed only on Nitro-based - // instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html#ec2-nitro-instances). - // Other instance families guarantee performance up to 32,000 IOPS. For more - // information, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) + // with a maximum ratio of 50 IOPS/GiB. Range is 100 to 32000 IOPS for volumes + // in most regions. For exceptions, see Amazon EBS Volume Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) // in the Amazon Elastic Compute Cloud User Guide. // // This parameter is valid only for Provisioned IOPS SSD (io1) volumes. Iops *int64 `type:"integer"` - // The identifier of the AWS Key Management Service (AWS KMS) customer master - // key (CMK) to use for Amazon EBS encryption. If this parameter is not specified, - // your AWS managed CMK for EBS is used. If KmsKeyId is specified, the encrypted - // state must be true. + // An identifier for the AWS Key Management Service (AWS KMS) customer master + // key (CMK) to use when creating the encrypted volume. This parameter is only + // required if you want to use a non-default CMK; if this parameter is not specified, + // the default CMK for EBS is used. If a KmsKeyId is specified, the Encrypted + // flag must also be set. // - // You can specify the CMK using any of the following: + // The CMK identifier may be provided in any of the following formats: // - // * Key ID. For example, key/1234abcd-12ab-34cd-56ef-1234567890ab. + // * Key ID // - // * Key alias. For example, alias/ExampleAlias. + // * Key alias // - // * Key ARN. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. + // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed + // by the region of the CMK, the AWS account ID of the CMK owner, the key + // namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. // - // * Alias ARN. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. // - // AWS authenticates the CMK asynchronously. Therefore, if you specify an ID, - // alias, or ARN that is not valid, the action can appear to complete, but eventually - // fails. + // * ARN using key alias. The alias ARN contains the arn:aws:kms namespace, + // followed by the region of the CMK, the AWS account ID of the CMK owner, + // the alias namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. + // + // + // AWS parses KmsKeyId asynchronously, meaning that the action you call may + // appear to complete even though you provided an invalid identifier. The action + // will eventually fail. KmsKeyId *string `type:"string"` // The size of the volume, in GiBs. // - // Constraints: 1-16,384 for gp2, 4-16,384 for io1, 500-16,384 for st1, 500-16,384 - // for sc1, and 1-1,024 for standard. If you specify a snapshot, the volume - // size must be equal to or larger than the snapshot size. + // Constraints: 1-16384 for gp2, 4-16384 for io1, 500-16384 for st1, 500-16384 + // for sc1, and 1-1024 for standard. If you specify a snapshot, the volume size + // must be equal to or larger than the snapshot size. // // Default: If you're creating the volume from a snapshot and don't specify // a volume size, the default is the snapshot size. - // - // At least one of Size or SnapshotId is required. Size *int64 `type:"integer"` // The snapshot from which to create the volume. - // - // At least one of Size or SnapshotId are required. SnapshotId *string `type:"string"` // The tags to apply to the volume during creation. @@ -43481,7 +30377,7 @@ type CreateVolumeInput struct { // Defaults: If no volume type is specified, the default is standard in us-east-1, // eu-west-1, eu-central-1, us-west-2, us-west-1, sa-east-1, ap-northeast-1, // ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, us-gov-west-1, - // and cn-north-1. In all other Regions, EBS defaults to gp2. + // and cn-north-1. In all other regions, EBS defaults to gp2. VolumeType *string `type:"string" enum:"VolumeType"` } @@ -43562,15 +30458,17 @@ func (s *CreateVolumeInput) SetVolumeType(v string) *CreateVolumeInput { return s } -// Describes the user or group to be added or removed from the list of create -// volume permissions for a volume. +// Describes the user or group to be added or removed from the permissions for +// a volume. type CreateVolumePermission struct { _ struct{} `type:"structure"` - // The group to be added or removed. The possible value is all. + // The specific group that is to be added or removed from a volume's list of + // create volume permissions. Group *string `locationName:"group" type:"string" enum:"PermissionGroup"` - // The AWS account ID to be added or removed. + // The specific AWS account ID that is to be added or removed from a volume's + // list of create volume permissions. UserId *string `locationName:"userId" type:"string"` } @@ -43596,14 +30494,16 @@ func (s *CreateVolumePermission) SetUserId(v string) *CreateVolumePermission { return s } -// Describes modifications to the list of create volume permissions for a volume. +// Describes modifications to the permissions for a volume. type CreateVolumePermissionModifications struct { _ struct{} `type:"structure"` - // Adds the specified AWS account ID or group to the list. + // Adds a specific AWS account ID or group to a volume's list of create volume + // permissions. Add []*CreateVolumePermission `locationNameList:"item" type:"list"` - // Removes the specified AWS account ID or group from the list. + // Removes a specific AWS account ID or group from a volume's list of create + // volume permissions. Remove []*CreateVolumePermission `locationNameList:"item" type:"list"` } @@ -43633,7 +30533,7 @@ type CreateVpcEndpointConnectionNotificationInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // One or more endpoint events for which to receive notifications. Valid values @@ -43760,7 +30660,7 @@ type CreateVpcEndpointInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -43769,14 +30669,15 @@ type CreateVpcEndpointInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // A policy to attach to the endpoint that controls access to the service. The - // policy must be in valid JSON format. If this parameter is not specified, - // we attach a default policy that allows full access to the service. + // (Gateway endpoint) A policy to attach to the endpoint that controls access + // to the service. The policy must be in valid JSON format. If this parameter + // is not specified, we attach a default policy that allows full access to the + // service. PolicyDocument *string `type:"string"` // (Interface endpoint) Indicate whether to associate a private hosted zone // with the specified VPC. The private hosted zone contains a record set for - // the default public DNS name for the service for the Region (for example, + // the default public DNS name for the service for the region (for example, // kinesis.us-east-1.amazonaws.com) which resolves to the private IP addresses // of the endpoint network interfaces in the VPC. This enables you to make requests // to the default public DNS name for the service instead of the public DNS @@ -43945,7 +30846,7 @@ type CreateVpcEndpointServiceConfigurationInput struct { AcceptanceRequired *bool `type:"boolean"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). + // the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -44041,6 +30942,7 @@ func (s *CreateVpcEndpointServiceConfigurationOutput) SetServiceConfiguration(v return s } +// Contains the parameters for CreateVpc. type CreateVpcInput struct { _ struct{} `type:"structure"` @@ -44120,6 +31022,7 @@ func (s *CreateVpcInput) SetInstanceTenancy(v string) *CreateVpcInput { return s } +// Contains the output of CreateVpc. type CreateVpcOutput struct { _ struct{} `type:"structure"` @@ -44143,6 +31046,7 @@ func (s *CreateVpcOutput) SetVpc(v *Vpc) *CreateVpcOutput { return s } +// Contains the parameters for CreateVpcPeeringConnection. type CreateVpcPeeringConnectionInput struct { _ struct{} `type:"structure"` @@ -44157,10 +31061,10 @@ type CreateVpcPeeringConnectionInput struct { // Default: Your AWS account ID PeerOwnerId *string `locationName:"peerOwnerId" type:"string"` - // The Region code for the accepter VPC, if the accepter VPC is located in a - // Region other than the Region in which you make the request. + // The region code for the accepter VPC, if the accepter VPC is located in a + // region other than the region in which you make the request. // - // Default: The Region in which you make the request. + // Default: The region in which you make the request. PeerRegion *string `type:"string"` // The ID of the VPC with which you are creating the VPC peering connection. @@ -44211,6 +31115,7 @@ func (s *CreateVpcPeeringConnectionInput) SetVpcId(v string) *CreateVpcPeeringCo return s } +// Contains the output of CreateVpcPeeringConnection. type CreateVpcPeeringConnectionOutput struct { _ struct{} `type:"structure"` @@ -44252,18 +31157,15 @@ type CreateVpnConnectionInput struct { // The options for the VPN connection. Options *VpnConnectionOptionsSpecification `locationName:"options" type:"structure"` - // The ID of the transit gateway. If you specify a transit gateway, you cannot - // specify a virtual private gateway. - TransitGatewayId *string `type:"string"` - // The type of VPN connection (ipsec.1). // // Type is a required field Type *string `type:"string" required:"true"` - // The ID of the virtual private gateway. If you specify a virtual private gateway, - // you cannot specify a transit gateway. - VpnGatewayId *string `type:"string"` + // The ID of the virtual private gateway. + // + // VpnGatewayId is a required field + VpnGatewayId *string `type:"string" required:"true"` } // String returns the string representation @@ -44285,6 +31187,9 @@ func (s *CreateVpnConnectionInput) Validate() error { if s.Type == nil { invalidParams.Add(request.NewErrParamRequired("Type")) } + if s.VpnGatewayId == nil { + invalidParams.Add(request.NewErrParamRequired("VpnGatewayId")) + } if invalidParams.Len() > 0 { return invalidParams @@ -44310,12 +31215,6 @@ func (s *CreateVpnConnectionInput) SetOptions(v *VpnConnectionOptionsSpecificati return s } -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *CreateVpnConnectionInput) SetTransitGatewayId(v string) *CreateVpnConnectionInput { - s.TransitGatewayId = &v - return s -} - // SetType sets the Type field's value. func (s *CreateVpnConnectionInput) SetType(v string) *CreateVpnConnectionInput { s.Type = &v @@ -44516,12 +31415,12 @@ func (s *CreateVpnGatewayOutput) SetVpnGateway(v *VpnGateway) *CreateVpnGatewayO return s } -// Describes the credit option for CPU usage of a T2 or T3 instance. +// Describes the credit option for CPU usage of a T2 instance. type CreditSpecification struct { _ struct{} `type:"structure"` - // The credit option for CPU usage of a T2 or T3 instance. Valid values are - // standard and unlimited. + // The credit option for CPU usage of a T2 instance. Valid values are standard + // and unlimited. CpuCredits *string `locationName:"cpuCredits" type:"string"` } @@ -44541,12 +31440,12 @@ func (s *CreditSpecification) SetCpuCredits(v string) *CreditSpecification { return s } -// The credit option for CPU usage of a T2 or T3 instance. +// The credit option for CPU usage of a T2 instance. type CreditSpecificationRequest struct { _ struct{} `type:"structure"` - // The credit option for CPU usage of a T2 or T3 instance. Valid values are - // standard and unlimited. + // The credit option for CPU usage of a T2 instance. Valid values are standard + // and unlimited. // // CpuCredits is a required field CpuCredits *string `type:"string" required:"true"` @@ -44652,175 +31551,6 @@ func (s *CustomerGateway) SetType(v string) *CustomerGateway { return s } -type DeleteClientVpnEndpointInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN to be deleted. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s DeleteClientVpnEndpointInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteClientVpnEndpointInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteClientVpnEndpointInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteClientVpnEndpointInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DeleteClientVpnEndpointInput) SetClientVpnEndpointId(v string) *DeleteClientVpnEndpointInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteClientVpnEndpointInput) SetDryRun(v bool) *DeleteClientVpnEndpointInput { - s.DryRun = &v - return s -} - -type DeleteClientVpnEndpointOutput struct { - _ struct{} `type:"structure"` - - // The current state of the Client VPN endpoint. - Status *ClientVpnEndpointStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s DeleteClientVpnEndpointOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteClientVpnEndpointOutput) GoString() string { - return s.String() -} - -// SetStatus sets the Status field's value. -func (s *DeleteClientVpnEndpointOutput) SetStatus(v *ClientVpnEndpointStatus) *DeleteClientVpnEndpointOutput { - s.Status = v - return s -} - -type DeleteClientVpnRouteInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint from which the route is to be deleted. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // The IPv4 address range, in CIDR notation, of the route to be deleted. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the target subnet used by the route. - TargetVpcSubnetId *string `type:"string"` -} - -// String returns the string representation -func (s DeleteClientVpnRouteInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteClientVpnRouteInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteClientVpnRouteInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteClientVpnRouteInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DeleteClientVpnRouteInput) SetClientVpnEndpointId(v string) *DeleteClientVpnRouteInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *DeleteClientVpnRouteInput) SetDestinationCidrBlock(v string) *DeleteClientVpnRouteInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteClientVpnRouteInput) SetDryRun(v bool) *DeleteClientVpnRouteInput { - s.DryRun = &v - return s -} - -// SetTargetVpcSubnetId sets the TargetVpcSubnetId field's value. -func (s *DeleteClientVpnRouteInput) SetTargetVpcSubnetId(v string) *DeleteClientVpnRouteInput { - s.TargetVpcSubnetId = &v - return s -} - -type DeleteClientVpnRouteOutput struct { - _ struct{} `type:"structure"` - - // The current state of the route. - Status *ClientVpnRouteStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s DeleteClientVpnRouteOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteClientVpnRouteOutput) GoString() string { - return s.String() -} - -// SetStatus sets the Status field's value. -func (s *DeleteClientVpnRouteOutput) SetStatus(v *ClientVpnRouteStatus) *DeleteClientVpnRouteOutput { - s.Status = v - return s -} - // Contains the parameters for DeleteCustomerGateway. type DeleteCustomerGatewayInput struct { _ struct{} `type:"structure"` @@ -44886,6 +31616,7 @@ func (s DeleteCustomerGatewayOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteDhcpOptions. type DeleteDhcpOptionsInput struct { _ struct{} `type:"structure"` @@ -45228,6 +31959,7 @@ func (s *DeleteFleetsOutput) SetUnsuccessfulFleetDeletions(v []*DeleteFleetError return s } +// Contains the parameters for DeleteFlowLogs. type DeleteFlowLogsInput struct { _ struct{} `type:"structure"` @@ -45239,8 +31971,6 @@ type DeleteFlowLogsInput struct { // One or more flow log IDs. // - // Constraint: Maximum of 1000 flow log IDs. - // // FlowLogIds is a required field FlowLogIds []*string `locationName:"FlowLogId" locationNameList:"item" type:"list" required:"true"` } @@ -45280,6 +32010,7 @@ func (s *DeleteFlowLogsInput) SetFlowLogIds(v []*string) *DeleteFlowLogsInput { return s } +// Contains the output of DeleteFlowLogs. type DeleteFlowLogsOutput struct { _ struct{} `type:"structure"` @@ -45376,6 +32107,7 @@ func (s *DeleteFpgaImageOutput) SetReturn(v bool) *DeleteFpgaImageOutput { return s } +// Contains the parameters for DeleteInternetGateway. type DeleteInternetGatewayInput struct { _ struct{} `type:"structure"` @@ -45440,6 +32172,7 @@ func (s DeleteInternetGatewayOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteKeyPair. type DeleteKeyPairInput struct { _ struct{} `type:"structure"` @@ -45784,6 +32517,7 @@ func (s *DeleteLaunchTemplateVersionsResponseSuccessItem) SetVersionNumber(v int return s } +// Contains the parameters for DeleteNatGateway. type DeleteNatGatewayInput struct { _ struct{} `type:"structure"` @@ -45822,6 +32556,7 @@ func (s *DeleteNatGatewayInput) SetNatGatewayId(v string) *DeleteNatGatewayInput return s } +// Contains the output of DeleteNatGateway. type DeleteNatGatewayOutput struct { _ struct{} `type:"structure"` @@ -45845,6 +32580,7 @@ func (s *DeleteNatGatewayOutput) SetNatGatewayId(v string) *DeleteNatGatewayOutp return s } +// Contains the parameters for DeleteNetworkAclEntry. type DeleteNetworkAclEntryInput struct { _ struct{} `type:"structure"` @@ -45937,6 +32673,7 @@ func (s DeleteNetworkAclEntryOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteNetworkAcl. type DeleteNetworkAclInput struct { _ struct{} `type:"structure"` @@ -46151,6 +32888,7 @@ func (s *DeleteNetworkInterfacePermissionOutput) SetReturn(v bool) *DeleteNetwor return s } +// Contains the parameters for DeletePlacementGroup. type DeletePlacementGroupInput struct { _ struct{} `type:"structure"` @@ -46215,6 +32953,7 @@ func (s DeletePlacementGroupOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteRoute. type DeleteRouteInput struct { _ struct{} `type:"structure"` @@ -46299,6 +33038,7 @@ func (s DeleteRouteOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteRouteTable. type DeleteRouteTableInput struct { _ struct{} `type:"structure"` @@ -46363,6 +33103,7 @@ func (s DeleteRouteTableOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteSecurityGroup. type DeleteSecurityGroupInput struct { _ struct{} `type:"structure"` @@ -46528,6 +33269,7 @@ func (s DeleteSpotDatafeedSubscriptionOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteSubnet. type DeleteSubnetInput struct { _ struct{} `type:"structure"` @@ -46592,6 +33334,7 @@ func (s DeleteSubnetOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteTags. type DeleteTagsInput struct { _ struct{} `type:"structure"` @@ -46601,17 +33344,14 @@ type DeleteTagsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the resources, separated by spaces. - // - // Constraints: Up to 1000 resource IDs. We recommend breaking up this request - // into smaller batches. + // The IDs of one or more resources. // // Resources is a required field Resources []*string `locationName:"resourceId" type:"list" required:"true"` - // The tags to delete. Specify a tag key and an optional tag value to delete - // specific tags. If you specify a tag key without a tag value, we delete any - // tag with this key regardless of its value. If you specify a tag key with + // One or more tags to delete. Specify a tag key and an optional tag value to + // delete specific tags. If you specify a tag key without a tag value, we delete + // any tag with this key regardless of its value. If you specify a tag key with // an empty string as the tag value, we delete the tag only if its value is // an empty string. // @@ -46675,604 +33415,6 @@ func (s DeleteTagsOutput) GoString() string { return s.String() } -type DeleteTrafficMirrorFilterInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the Traffic Mirror filter. - // - // TrafficMirrorFilterId is a required field - TrafficMirrorFilterId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorFilterInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorFilterInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTrafficMirrorFilterInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTrafficMirrorFilterInput"} - if s.TrafficMirrorFilterId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTrafficMirrorFilterInput) SetDryRun(v bool) *DeleteTrafficMirrorFilterInput { - s.DryRun = &v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *DeleteTrafficMirrorFilterInput) SetTrafficMirrorFilterId(v string) *DeleteTrafficMirrorFilterInput { - s.TrafficMirrorFilterId = &v - return s -} - -type DeleteTrafficMirrorFilterOutput struct { - _ struct{} `type:"structure"` - - // The ID of the Traffic Mirror filter. - TrafficMirrorFilterId *string `locationName:"trafficMirrorFilterId" type:"string"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorFilterOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorFilterOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *DeleteTrafficMirrorFilterOutput) SetTrafficMirrorFilterId(v string) *DeleteTrafficMirrorFilterOutput { - s.TrafficMirrorFilterId = &v - return s -} - -type DeleteTrafficMirrorFilterRuleInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the Traffic Mirror rule. - // - // TrafficMirrorFilterRuleId is a required field - TrafficMirrorFilterRuleId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorFilterRuleInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorFilterRuleInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTrafficMirrorFilterRuleInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTrafficMirrorFilterRuleInput"} - if s.TrafficMirrorFilterRuleId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterRuleId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTrafficMirrorFilterRuleInput) SetDryRun(v bool) *DeleteTrafficMirrorFilterRuleInput { - s.DryRun = &v - return s -} - -// SetTrafficMirrorFilterRuleId sets the TrafficMirrorFilterRuleId field's value. -func (s *DeleteTrafficMirrorFilterRuleInput) SetTrafficMirrorFilterRuleId(v string) *DeleteTrafficMirrorFilterRuleInput { - s.TrafficMirrorFilterRuleId = &v - return s -} - -type DeleteTrafficMirrorFilterRuleOutput struct { - _ struct{} `type:"structure"` - - // The ID of the deleted Traffic Mirror rule. - TrafficMirrorFilterRuleId *string `locationName:"trafficMirrorFilterRuleId" type:"string"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorFilterRuleOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorFilterRuleOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorFilterRuleId sets the TrafficMirrorFilterRuleId field's value. -func (s *DeleteTrafficMirrorFilterRuleOutput) SetTrafficMirrorFilterRuleId(v string) *DeleteTrafficMirrorFilterRuleOutput { - s.TrafficMirrorFilterRuleId = &v - return s -} - -type DeleteTrafficMirrorSessionInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the Traffic Mirror session. - // - // TrafficMirrorSessionId is a required field - TrafficMirrorSessionId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorSessionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorSessionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTrafficMirrorSessionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTrafficMirrorSessionInput"} - if s.TrafficMirrorSessionId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorSessionId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTrafficMirrorSessionInput) SetDryRun(v bool) *DeleteTrafficMirrorSessionInput { - s.DryRun = &v - return s -} - -// SetTrafficMirrorSessionId sets the TrafficMirrorSessionId field's value. -func (s *DeleteTrafficMirrorSessionInput) SetTrafficMirrorSessionId(v string) *DeleteTrafficMirrorSessionInput { - s.TrafficMirrorSessionId = &v - return s -} - -type DeleteTrafficMirrorSessionOutput struct { - _ struct{} `type:"structure"` - - // The ID of the deleted Traffic Mirror session. - TrafficMirrorSessionId *string `locationName:"trafficMirrorSessionId" type:"string"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorSessionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorSessionOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorSessionId sets the TrafficMirrorSessionId field's value. -func (s *DeleteTrafficMirrorSessionOutput) SetTrafficMirrorSessionId(v string) *DeleteTrafficMirrorSessionOutput { - s.TrafficMirrorSessionId = &v - return s -} - -type DeleteTrafficMirrorTargetInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the Traffic Mirror target. - // - // TrafficMirrorTargetId is a required field - TrafficMirrorTargetId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorTargetInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorTargetInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTrafficMirrorTargetInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTrafficMirrorTargetInput"} - if s.TrafficMirrorTargetId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorTargetId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTrafficMirrorTargetInput) SetDryRun(v bool) *DeleteTrafficMirrorTargetInput { - s.DryRun = &v - return s -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *DeleteTrafficMirrorTargetInput) SetTrafficMirrorTargetId(v string) *DeleteTrafficMirrorTargetInput { - s.TrafficMirrorTargetId = &v - return s -} - -type DeleteTrafficMirrorTargetOutput struct { - _ struct{} `type:"structure"` - - // The ID of the deleted Traffic Mirror target. - TrafficMirrorTargetId *string `locationName:"trafficMirrorTargetId" type:"string"` -} - -// String returns the string representation -func (s DeleteTrafficMirrorTargetOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTrafficMirrorTargetOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *DeleteTrafficMirrorTargetOutput) SetTrafficMirrorTargetId(v string) *DeleteTrafficMirrorTargetOutput { - s.TrafficMirrorTargetId = &v - return s -} - -type DeleteTransitGatewayInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the transit gateway. - // - // TransitGatewayId is a required field - TransitGatewayId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTransitGatewayInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTransitGatewayInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTransitGatewayInput"} - if s.TransitGatewayId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTransitGatewayInput) SetDryRun(v bool) *DeleteTransitGatewayInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *DeleteTransitGatewayInput) SetTransitGatewayId(v string) *DeleteTransitGatewayInput { - s.TransitGatewayId = &v - return s -} - -type DeleteTransitGatewayOutput struct { - _ struct{} `type:"structure"` - - // Information about the deleted transit gateway. - TransitGateway *TransitGateway `locationName:"transitGateway" type:"structure"` -} - -// String returns the string representation -func (s DeleteTransitGatewayOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayOutput) GoString() string { - return s.String() -} - -// SetTransitGateway sets the TransitGateway field's value. -func (s *DeleteTransitGatewayOutput) SetTransitGateway(v *TransitGateway) *DeleteTransitGatewayOutput { - s.TransitGateway = v - return s -} - -type DeleteTransitGatewayRouteInput struct { - _ struct{} `type:"structure"` - - // The CIDR range for the route. This must match the CIDR for the route exactly. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTransitGatewayRouteInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayRouteInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTransitGatewayRouteInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTransitGatewayRouteInput"} - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *DeleteTransitGatewayRouteInput) SetDestinationCidrBlock(v string) *DeleteTransitGatewayRouteInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTransitGatewayRouteInput) SetDryRun(v bool) *DeleteTransitGatewayRouteInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *DeleteTransitGatewayRouteInput) SetTransitGatewayRouteTableId(v string) *DeleteTransitGatewayRouteInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type DeleteTransitGatewayRouteOutput struct { - _ struct{} `type:"structure"` - - // Information about the route. - Route *TransitGatewayRoute `locationName:"route" type:"structure"` -} - -// String returns the string representation -func (s DeleteTransitGatewayRouteOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayRouteOutput) GoString() string { - return s.String() -} - -// SetRoute sets the Route field's value. -func (s *DeleteTransitGatewayRouteOutput) SetRoute(v *TransitGatewayRoute) *DeleteTransitGatewayRouteOutput { - s.Route = v - return s -} - -type DeleteTransitGatewayRouteTableInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTransitGatewayRouteTableInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayRouteTableInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTransitGatewayRouteTableInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTransitGatewayRouteTableInput"} - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTransitGatewayRouteTableInput) SetDryRun(v bool) *DeleteTransitGatewayRouteTableInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *DeleteTransitGatewayRouteTableInput) SetTransitGatewayRouteTableId(v string) *DeleteTransitGatewayRouteTableInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type DeleteTransitGatewayRouteTableOutput struct { - _ struct{} `type:"structure"` - - // Information about the deleted transit gateway route table. - TransitGatewayRouteTable *TransitGatewayRouteTable `locationName:"transitGatewayRouteTable" type:"structure"` -} - -// String returns the string representation -func (s DeleteTransitGatewayRouteTableOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayRouteTableOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayRouteTable sets the TransitGatewayRouteTable field's value. -func (s *DeleteTransitGatewayRouteTableOutput) SetTransitGatewayRouteTable(v *TransitGatewayRouteTable) *DeleteTransitGatewayRouteTableOutput { - s.TransitGatewayRouteTable = v - return s -} - -type DeleteTransitGatewayVpcAttachmentInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DeleteTransitGatewayVpcAttachmentInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayVpcAttachmentInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteTransitGatewayVpcAttachmentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteTransitGatewayVpcAttachmentInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DeleteTransitGatewayVpcAttachmentInput) SetDryRun(v bool) *DeleteTransitGatewayVpcAttachmentInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *DeleteTransitGatewayVpcAttachmentInput) SetTransitGatewayAttachmentId(v string) *DeleteTransitGatewayVpcAttachmentInput { - s.TransitGatewayAttachmentId = &v - return s -} - -type DeleteTransitGatewayVpcAttachmentOutput struct { - _ struct{} `type:"structure"` - - // Information about the deleted VPC attachment. - TransitGatewayVpcAttachment *TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachment" type:"structure"` -} - -// String returns the string representation -func (s DeleteTransitGatewayVpcAttachmentOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeleteTransitGatewayVpcAttachmentOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayVpcAttachment sets the TransitGatewayVpcAttachment field's value. -func (s *DeleteTransitGatewayVpcAttachmentOutput) SetTransitGatewayVpcAttachment(v *TransitGatewayVpcAttachment) *DeleteTransitGatewayVpcAttachmentOutput { - s.TransitGatewayVpcAttachment = v - return s -} - // Contains the parameters for DeleteVolume. type DeleteVolumeInput struct { _ struct{} `type:"structure"` @@ -47559,6 +33701,7 @@ func (s *DeleteVpcEndpointsOutput) SetUnsuccessful(v []*UnsuccessfulItem) *Delet return s } +// Contains the parameters for DeleteVpc. type DeleteVpcInput struct { _ struct{} `type:"structure"` @@ -47623,6 +33766,7 @@ func (s DeleteVpcOutput) GoString() string { return s.String() } +// Contains the parameters for DeleteVpcPeeringConnection. type DeleteVpcPeeringConnectionInput struct { _ struct{} `type:"structure"` @@ -47673,6 +33817,7 @@ func (s *DeleteVpcPeeringConnectionInput) SetVpcPeeringConnectionId(v string) *D return s } +// Contains the output of DeleteVpcPeeringConnection. type DeleteVpcPeeringConnectionOutput struct { _ struct{} `type:"structure"` @@ -47893,80 +34038,6 @@ func (s DeleteVpnGatewayOutput) GoString() string { return s.String() } -type DeprovisionByoipCidrInput struct { - _ struct{} `type:"structure"` - - // The public IPv4 address range, in CIDR notation. The prefix must be the same - // prefix that you specified when you provisioned the address range. - // - // Cidr is a required field - Cidr *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s DeprovisionByoipCidrInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeprovisionByoipCidrInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeprovisionByoipCidrInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeprovisionByoipCidrInput"} - if s.Cidr == nil { - invalidParams.Add(request.NewErrParamRequired("Cidr")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCidr sets the Cidr field's value. -func (s *DeprovisionByoipCidrInput) SetCidr(v string) *DeprovisionByoipCidrInput { - s.Cidr = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DeprovisionByoipCidrInput) SetDryRun(v bool) *DeprovisionByoipCidrInput { - s.DryRun = &v - return s -} - -type DeprovisionByoipCidrOutput struct { - _ struct{} `type:"structure"` - - // Information about the address range. - ByoipCidr *ByoipCidr `locationName:"byoipCidr" type:"structure"` -} - -// String returns the string representation -func (s DeprovisionByoipCidrOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DeprovisionByoipCidrOutput) GoString() string { - return s.String() -} - -// SetByoipCidr sets the ByoipCidr field's value. -func (s *DeprovisionByoipCidrOutput) SetByoipCidr(v *ByoipCidr) *DeprovisionByoipCidrOutput { - s.ByoipCidr = v - return s -} - // Contains the parameters for DeregisterImage. type DeregisterImageInput struct { _ struct{} `type:"structure"` @@ -48032,10 +34103,11 @@ func (s DeregisterImageOutput) GoString() string { return s.String() } +// Contains the parameters for DescribeAccountAttributes. type DescribeAccountAttributesInput struct { _ struct{} `type:"structure"` - // The account attribute names. + // One or more account attribute names. AttributeNames []*string `locationName:"attributeName" locationNameList:"attributeName" type:"list"` // Checks whether you have the required permissions for the action, without @@ -48067,10 +34139,11 @@ func (s *DescribeAccountAttributesInput) SetDryRun(v bool) *DescribeAccountAttri return s } +// Contains the output of DescribeAccountAttributes. type DescribeAccountAttributesOutput struct { _ struct{} `type:"structure"` - // Information about the account attributes. + // Information about one or more account attributes. AccountAttributes []*AccountAttribute `locationName:"accountAttributeSet" locationNameList:"item" type:"list"` } @@ -48090,10 +34163,13 @@ func (s *DescribeAccountAttributesOutput) SetAccountAttributes(v []*AccountAttri return s } +// Contains the parameters for DescribeAddresses. type DescribeAddressesInput struct { _ struct{} `type:"structure"` - // [EC2-VPC] Information about the allocation IDs. + // [EC2-VPC] One or more allocation IDs. + // + // Default: Describes all your Elastic IP addresses. AllocationIds []*string `locationName:"AllocationId" locationNameList:"AllocationId" type:"list"` // Checks whether you have the required permissions for the action, without @@ -48135,7 +34211,7 @@ type DescribeAddressesInput struct { // the tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // One or more Elastic IP addresses. + // [EC2-Classic] One or more Elastic IP addresses. // // Default: Describes all your Elastic IP addresses. PublicIps []*string `locationName:"PublicIp" locationNameList:"PublicIp" type:"list"` @@ -48175,10 +34251,11 @@ func (s *DescribeAddressesInput) SetPublicIps(v []*string) *DescribeAddressesInp return s } +// Contains the output of DescribeAddresses. type DescribeAddressesOutput struct { _ struct{} `type:"structure"` - // Information about the Elastic IP addresses. + // Information about one or more Elastic IP addresses. Addresses []*Address `locationName:"addressesSet" locationNameList:"item" type:"list"` } @@ -48230,9 +34307,9 @@ type DescribeAggregateIdFormatOutput struct { // Information about each resource's ID format. Statuses []*IdFormat `locationName:"statusSet" locationNameList:"item" type:"list"` - // Indicates whether all resource types in the Region are configured to use + // Indicates whether all resource types in the region are configured to use // longer IDs. This value is only true if all users are configured to use longer - // IDs for all resources types in the Region. + // IDs for all resources types in the region. UseLongIdsAggregated *bool `locationName:"useLongIdsAggregated" type:"boolean"` } @@ -48258,6 +34335,7 @@ func (s *DescribeAggregateIdFormatOutput) SetUseLongIdsAggregated(v bool) *Descr return s } +// Contains the parameters for DescribeAvailabilityZones. type DescribeAvailabilityZonesInput struct { _ struct{} `type:"structure"` @@ -48267,25 +34345,20 @@ type DescribeAvailabilityZonesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * message - Information about the Availability Zone. // - // * region-name - The name of the Region for the Availability Zone (for + // * region-name - The name of the region for the Availability Zone (for // example, us-east-1). // // * state - The state of the Availability Zone (available | information // | impaired | unavailable). // - // * zone-id - The ID of the Availability Zone (for example, use1-az1). - // // * zone-name - The name of the Availability Zone (for example, us-east-1a). Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The IDs of the Availability Zones. - ZoneIds []*string `locationName:"ZoneId" locationNameList:"ZoneId" type:"list"` - - // The names of the Availability Zones. + // The names of one or more Availability Zones. ZoneNames []*string `locationName:"ZoneName" locationNameList:"ZoneName" type:"list"` } @@ -48311,22 +34384,17 @@ func (s *DescribeAvailabilityZonesInput) SetFilters(v []*Filter) *DescribeAvaila return s } -// SetZoneIds sets the ZoneIds field's value. -func (s *DescribeAvailabilityZonesInput) SetZoneIds(v []*string) *DescribeAvailabilityZonesInput { - s.ZoneIds = v - return s -} - // SetZoneNames sets the ZoneNames field's value. func (s *DescribeAvailabilityZonesInput) SetZoneNames(v []*string) *DescribeAvailabilityZonesInput { s.ZoneNames = v return s } +// Contains the output of DescribeAvailabiltyZones. type DescribeAvailabilityZonesOutput struct { _ struct{} `type:"structure"` - // Information about the Availability Zones. + // Information about one or more Availability Zones. AvailabilityZones []*AvailabilityZone `locationName:"availabilityZoneInfo" locationNameList:"item" type:"list"` } @@ -48346,10 +34414,11 @@ func (s *DescribeAvailabilityZonesOutput) SetAvailabilityZones(v []*Availability return s } +// Contains the parameters for DescribeBundleTasks. type DescribeBundleTasksInput struct { _ struct{} `type:"structure"` - // The bundle task IDs. + // One or more bundle task IDs. // // Default: Describes all your bundle tasks. BundleIds []*string `locationName:"BundleId" locationNameList:"BundleId" type:"list"` @@ -48360,7 +34429,7 @@ type DescribeBundleTasksInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * bundle-id - The ID of the bundle task. // @@ -48414,10 +34483,11 @@ func (s *DescribeBundleTasksInput) SetFilters(v []*Filter) *DescribeBundleTasksI return s } +// Contains the output of DescribeBundleTasks. type DescribeBundleTasksOutput struct { _ struct{} `type:"structure"` - // Information about the bundle tasks. + // Information about one or more bundle tasks. BundleTasks []*BundleTask `locationName:"bundleInstanceTasksSet" locationNameList:"item" type:"list"` } @@ -48437,212 +34507,7 @@ func (s *DescribeBundleTasksOutput) SetBundleTasks(v []*BundleTask) *DescribeBun return s } -type DescribeByoipCidrsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - // - // MaxResults is a required field - MaxResults *int64 `min:"1" type:"integer" required:"true"` - - // The token for the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeByoipCidrsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeByoipCidrsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeByoipCidrsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeByoipCidrsInput"} - if s.MaxResults == nil { - invalidParams.Add(request.NewErrParamRequired("MaxResults")) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeByoipCidrsInput) SetDryRun(v bool) *DescribeByoipCidrsInput { - s.DryRun = &v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeByoipCidrsInput) SetMaxResults(v int64) *DescribeByoipCidrsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeByoipCidrsInput) SetNextToken(v string) *DescribeByoipCidrsInput { - s.NextToken = &v - return s -} - -type DescribeByoipCidrsOutput struct { - _ struct{} `type:"structure"` - - // Information about your address ranges. - ByoipCidrs []*ByoipCidr `locationName:"byoipCidrSet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeByoipCidrsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeByoipCidrsOutput) GoString() string { - return s.String() -} - -// SetByoipCidrs sets the ByoipCidrs field's value. -func (s *DescribeByoipCidrsOutput) SetByoipCidrs(v []*ByoipCidr) *DescribeByoipCidrsOutput { - s.ByoipCidrs = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeByoipCidrsOutput) SetNextToken(v string) *DescribeByoipCidrsOutput { - s.NextToken = &v - return s -} - -type DescribeCapacityReservationsInput struct { - _ struct{} `type:"structure"` - - // The ID of the Capacity Reservation. - CapacityReservationIds []*string `locationName:"CapacityReservationId" locationNameList:"item" type:"list"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the returned - // nextToken value. - MaxResults *int64 `min:"1" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeCapacityReservationsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCapacityReservationsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeCapacityReservationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeCapacityReservationsInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCapacityReservationIds sets the CapacityReservationIds field's value. -func (s *DescribeCapacityReservationsInput) SetCapacityReservationIds(v []*string) *DescribeCapacityReservationsInput { - s.CapacityReservationIds = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeCapacityReservationsInput) SetDryRun(v bool) *DescribeCapacityReservationsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeCapacityReservationsInput) SetFilters(v []*Filter) *DescribeCapacityReservationsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeCapacityReservationsInput) SetMaxResults(v int64) *DescribeCapacityReservationsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeCapacityReservationsInput) SetNextToken(v string) *DescribeCapacityReservationsInput { - s.NextToken = &v - return s -} - -type DescribeCapacityReservationsOutput struct { - _ struct{} `type:"structure"` - - // Information about the Capacity Reservations. - CapacityReservations []*CapacityReservation `locationName:"capacityReservationSet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeCapacityReservationsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeCapacityReservationsOutput) GoString() string { - return s.String() -} - -// SetCapacityReservations sets the CapacityReservations field's value. -func (s *DescribeCapacityReservationsOutput) SetCapacityReservations(v []*CapacityReservation) *DescribeCapacityReservationsOutput { - s.CapacityReservations = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeCapacityReservationsOutput) SetNextToken(v string) *DescribeCapacityReservationsOutput { - s.NextToken = &v - return s -} - +// Contains the parameters for DescribeClassicLinkInstances. type DescribeClassicLinkInstancesInput struct { _ struct{} `type:"structure"` @@ -48669,20 +34534,25 @@ type DescribeClassicLinkInstancesInput struct { // to find all resources assigned a tag with a specific key, regardless of // the tag value. // - // * vpc-id - The ID of the VPC to which the instance is linked. vpc-id - - // The ID of the VPC that the instance is linked to. + // * vpc-id - The ID of the VPC to which the instance is linked. + // + // vpc-id - The ID of the VPC that the instance is linked to. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // One or more instance IDs. Must be instances linked to a VPC through ClassicLink. InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. + // The maximum number of results to return for the request in a single page. + // The remaining results of the initial request can be seen by sending another + // request with the returned NextToken value. This value can be between 5 and + // 1000. If MaxResults is given a value larger than 1000, only 1000 results + // are returned. You cannot specify this parameter and the instance IDs parameter + // in the same request. // // Constraint: If the value is greater than 1000, we return only 1000 items. - MaxResults *int64 `locationName:"maxResults" min:"5" type:"integer"` + MaxResults *int64 `locationName:"maxResults" type:"integer"` - // The token for the next page of results. + // The token to retrieve the next page of results. NextToken *string `locationName:"nextToken" type:"string"` } @@ -48696,19 +34566,6 @@ func (s DescribeClassicLinkInstancesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClassicLinkInstancesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClassicLinkInstancesInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeClassicLinkInstancesInput) SetDryRun(v bool) *DescribeClassicLinkInstancesInput { s.DryRun = &v @@ -48739,6 +34596,7 @@ func (s *DescribeClassicLinkInstancesInput) SetNextToken(v string) *DescribeClas return s } +// Contains the output of DescribeClassicLinkInstances. type DescribeClassicLinkInstancesOutput struct { _ struct{} `type:"structure"` @@ -48772,589 +34630,11 @@ func (s *DescribeClassicLinkInstancesOutput) SetNextToken(v string) *DescribeCla return s } -type DescribeClientVpnAuthorizationRulesInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. Filter names and values are case-sensitive. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the nextToken - // value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnAuthorizationRulesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnAuthorizationRulesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClientVpnAuthorizationRulesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClientVpnAuthorizationRulesInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DescribeClientVpnAuthorizationRulesInput) SetClientVpnEndpointId(v string) *DescribeClientVpnAuthorizationRulesInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeClientVpnAuthorizationRulesInput) SetDryRun(v bool) *DescribeClientVpnAuthorizationRulesInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeClientVpnAuthorizationRulesInput) SetFilters(v []*Filter) *DescribeClientVpnAuthorizationRulesInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeClientVpnAuthorizationRulesInput) SetMaxResults(v int64) *DescribeClientVpnAuthorizationRulesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnAuthorizationRulesInput) SetNextToken(v string) *DescribeClientVpnAuthorizationRulesInput { - s.NextToken = &v - return s -} - -type DescribeClientVpnAuthorizationRulesOutput struct { - _ struct{} `type:"structure"` - - // Information about the authorization rules. - AuthorizationRules []*AuthorizationRule `locationName:"authorizationRule" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnAuthorizationRulesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnAuthorizationRulesOutput) GoString() string { - return s.String() -} - -// SetAuthorizationRules sets the AuthorizationRules field's value. -func (s *DescribeClientVpnAuthorizationRulesOutput) SetAuthorizationRules(v []*AuthorizationRule) *DescribeClientVpnAuthorizationRulesOutput { - s.AuthorizationRules = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnAuthorizationRulesOutput) SetNextToken(v string) *DescribeClientVpnAuthorizationRulesOutput { - s.NextToken = &v - return s -} - -type DescribeClientVpnConnectionsInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. Filter names and values are case-sensitive. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the nextToken - // value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnConnectionsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnConnectionsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClientVpnConnectionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClientVpnConnectionsInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DescribeClientVpnConnectionsInput) SetClientVpnEndpointId(v string) *DescribeClientVpnConnectionsInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeClientVpnConnectionsInput) SetDryRun(v bool) *DescribeClientVpnConnectionsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeClientVpnConnectionsInput) SetFilters(v []*Filter) *DescribeClientVpnConnectionsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeClientVpnConnectionsInput) SetMaxResults(v int64) *DescribeClientVpnConnectionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnConnectionsInput) SetNextToken(v string) *DescribeClientVpnConnectionsInput { - s.NextToken = &v - return s -} - -type DescribeClientVpnConnectionsOutput struct { - _ struct{} `type:"structure"` - - // Information about the active and terminated client connections. - Connections []*ClientVpnConnection `locationName:"connections" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnConnectionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnConnectionsOutput) GoString() string { - return s.String() -} - -// SetConnections sets the Connections field's value. -func (s *DescribeClientVpnConnectionsOutput) SetConnections(v []*ClientVpnConnection) *DescribeClientVpnConnectionsOutput { - s.Connections = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnConnectionsOutput) SetNextToken(v string) *DescribeClientVpnConnectionsOutput { - s.NextToken = &v - return s -} - -type DescribeClientVpnEndpointsInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - ClientVpnEndpointIds []*string `locationName:"ClientVpnEndpointId" locationNameList:"item" type:"list"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. Filter names and values are case-sensitive. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the nextToken - // value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnEndpointsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnEndpointsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClientVpnEndpointsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClientVpnEndpointsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointIds sets the ClientVpnEndpointIds field's value. -func (s *DescribeClientVpnEndpointsInput) SetClientVpnEndpointIds(v []*string) *DescribeClientVpnEndpointsInput { - s.ClientVpnEndpointIds = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeClientVpnEndpointsInput) SetDryRun(v bool) *DescribeClientVpnEndpointsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeClientVpnEndpointsInput) SetFilters(v []*Filter) *DescribeClientVpnEndpointsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeClientVpnEndpointsInput) SetMaxResults(v int64) *DescribeClientVpnEndpointsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnEndpointsInput) SetNextToken(v string) *DescribeClientVpnEndpointsInput { - s.NextToken = &v - return s -} - -type DescribeClientVpnEndpointsOutput struct { - _ struct{} `type:"structure"` - - // Information about the Client VPN endpoints. - ClientVpnEndpoints []*ClientVpnEndpoint `locationName:"clientVpnEndpoint" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnEndpointsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnEndpointsOutput) GoString() string { - return s.String() -} - -// SetClientVpnEndpoints sets the ClientVpnEndpoints field's value. -func (s *DescribeClientVpnEndpointsOutput) SetClientVpnEndpoints(v []*ClientVpnEndpoint) *DescribeClientVpnEndpointsOutput { - s.ClientVpnEndpoints = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnEndpointsOutput) SetNextToken(v string) *DescribeClientVpnEndpointsOutput { - s.NextToken = &v - return s -} - -type DescribeClientVpnRoutesInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. Filter names and values are case-sensitive. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the nextToken - // value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnRoutesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnRoutesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClientVpnRoutesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClientVpnRoutesInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DescribeClientVpnRoutesInput) SetClientVpnEndpointId(v string) *DescribeClientVpnRoutesInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeClientVpnRoutesInput) SetDryRun(v bool) *DescribeClientVpnRoutesInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeClientVpnRoutesInput) SetFilters(v []*Filter) *DescribeClientVpnRoutesInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeClientVpnRoutesInput) SetMaxResults(v int64) *DescribeClientVpnRoutesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnRoutesInput) SetNextToken(v string) *DescribeClientVpnRoutesInput { - s.NextToken = &v - return s -} - -type DescribeClientVpnRoutesOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the Client VPN endpoint routes. - Routes []*ClientVpnRoute `locationName:"routes" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeClientVpnRoutesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnRoutesOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnRoutesOutput) SetNextToken(v string) *DescribeClientVpnRoutesOutput { - s.NextToken = &v - return s -} - -// SetRoutes sets the Routes field's value. -func (s *DescribeClientVpnRoutesOutput) SetRoutes(v []*ClientVpnRoute) *DescribeClientVpnRoutesOutput { - s.Routes = v - return s -} - -type DescribeClientVpnTargetNetworksInput struct { - _ struct{} `type:"structure"` - - // The IDs of the target network associations. - AssociationIds []*string `locationNameList:"item" type:"list"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. Filter names and values are case-sensitive. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return for the request in a single page. - // The remaining results can be seen by sending another request with the nextToken - // value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnTargetNetworksInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnTargetNetworksInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeClientVpnTargetNetworksInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeClientVpnTargetNetworksInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAssociationIds sets the AssociationIds field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetAssociationIds(v []*string) *DescribeClientVpnTargetNetworksInput { - s.AssociationIds = v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetClientVpnEndpointId(v string) *DescribeClientVpnTargetNetworksInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetDryRun(v bool) *DescribeClientVpnTargetNetworksInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetFilters(v []*Filter) *DescribeClientVpnTargetNetworksInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetMaxResults(v int64) *DescribeClientVpnTargetNetworksInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnTargetNetworksInput) SetNextToken(v string) *DescribeClientVpnTargetNetworksInput { - s.NextToken = &v - return s -} - -type DescribeClientVpnTargetNetworksOutput struct { - _ struct{} `type:"structure"` - - // Information about the associated target networks. - ClientVpnTargetNetworks []*TargetNetwork `locationName:"clientVpnTargetNetworks" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s DescribeClientVpnTargetNetworksOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeClientVpnTargetNetworksOutput) GoString() string { - return s.String() -} - -// SetClientVpnTargetNetworks sets the ClientVpnTargetNetworks field's value. -func (s *DescribeClientVpnTargetNetworksOutput) SetClientVpnTargetNetworks(v []*TargetNetwork) *DescribeClientVpnTargetNetworksOutput { - s.ClientVpnTargetNetworks = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeClientVpnTargetNetworksOutput) SetNextToken(v string) *DescribeClientVpnTargetNetworksOutput { - s.NextToken = &v - return s -} - +// Contains the parameters for DescribeConversionTasks. type DescribeConversionTasksInput struct { _ struct{} `type:"structure"` - // The conversion task IDs. + // One or more conversion task IDs. ConversionTaskIds []*string `locationName:"conversionTaskId" locationNameList:"item" type:"list"` // Checks whether you have the required permissions for the action, without @@ -49386,6 +34666,7 @@ func (s *DescribeConversionTasksInput) SetDryRun(v bool) *DescribeConversionTask return s } +// Contains the output for DescribeConversionTasks. type DescribeConversionTasksOutput struct { _ struct{} `type:"structure"` @@ -49504,6 +34785,7 @@ func (s *DescribeCustomerGatewaysOutput) SetCustomerGateways(v []*CustomerGatewa return s } +// Contains the parameters for DescribeDhcpOptions. type DescribeDhcpOptionsInput struct { _ struct{} `type:"structure"` @@ -49520,14 +34802,12 @@ type DescribeDhcpOptionsInput struct { // One or more filters. // - // * dhcp-options-id - The ID of a DHCP options set. + // * dhcp-options-id - The ID of a set of DHCP options. // // * key - The key for one of the options (for example, domain-name). // // * value - The value for one of the options. // - // * owner-id - The ID of the AWS account that owns the DHCP options set. - // // * tag: - The key/value combination of a tag assigned to the resource. // Use the tag key in the filter name and the tag value as the filter value. // For example, to find all resources that have a tag with the key Owner @@ -49538,13 +34818,6 @@ type DescribeDhcpOptionsInput struct { // to find all resources assigned a tag with a specific key, regardless of // the tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` } // String returns the string representation @@ -49557,19 +34830,6 @@ func (s DescribeDhcpOptionsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeDhcpOptionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeDhcpOptionsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDhcpOptionsIds sets the DhcpOptionsIds field's value. func (s *DescribeDhcpOptionsInput) SetDhcpOptionsIds(v []*string) *DescribeDhcpOptionsInput { s.DhcpOptionsIds = v @@ -49588,27 +34848,12 @@ func (s *DescribeDhcpOptionsInput) SetFilters(v []*Filter) *DescribeDhcpOptionsI return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeDhcpOptionsInput) SetMaxResults(v int64) *DescribeDhcpOptionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeDhcpOptionsInput) SetNextToken(v string) *DescribeDhcpOptionsInput { - s.NextToken = &v - return s -} - +// Contains the output of DescribeDhcpOptions. type DescribeDhcpOptionsOutput struct { _ struct{} `type:"structure"` // Information about one or more DHCP options sets. DhcpOptions []*DhcpOptions `locationName:"dhcpOptionsSet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` } // String returns the string representation @@ -49627,12 +34872,6 @@ func (s *DescribeDhcpOptionsOutput) SetDhcpOptions(v []*DhcpOptions) *DescribeDh return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeDhcpOptionsOutput) SetNextToken(v string) *DescribeDhcpOptionsOutput { - s.NextToken = &v - return s -} - type DescribeEgressOnlyInternetGatewaysInput struct { _ struct{} `type:"structure"` @@ -49645,11 +34884,13 @@ type DescribeEgressOnlyInternetGatewaysInput struct { // One or more egress-only internet gateway IDs. EgressOnlyInternetGatewayIds []*string `locationName:"EgressOnlyInternetGatewayId" locationNameList:"item" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` + // The maximum number of results to return for the request in a single page. + // The remaining results can be seen by sending another request with the returned + // NextToken value. This value can be between 5 and 1000. If MaxResults is given + // a value larger than 1000, only 1000 results are returned. + MaxResults *int64 `type:"integer"` - // The token for the next page of results. + // The token to retrieve the next page of results. NextToken *string `type:"string"` } @@ -49663,19 +34904,6 @@ func (s DescribeEgressOnlyInternetGatewaysInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeEgressOnlyInternetGatewaysInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeEgressOnlyInternetGatewaysInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeEgressOnlyInternetGatewaysInput) SetDryRun(v bool) *DescribeEgressOnlyInternetGatewaysInput { s.DryRun = &v @@ -49706,8 +34934,7 @@ type DescribeEgressOnlyInternetGatewaysOutput struct { // Information about the egress-only internet gateways. EgressOnlyInternetGateways []*EgressOnlyInternetGateway `locationName:"egressOnlyInternetGatewaySet" locationNameList:"item" type:"list"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. + // The token to use to retrieve the next page of results. NextToken *string `locationName:"nextToken" type:"string"` } @@ -49742,30 +34969,26 @@ type DescribeElasticGpusInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The Elastic Graphics accelerator IDs. + // One or more Elastic GPU IDs. ElasticGpuIds []*string `locationName:"ElasticGpuId" locationNameList:"item" type:"list"` - // The filters. + // One or more filters. // - // * availability-zone - The Availability Zone in which the Elastic Graphics - // accelerator resides. + // * availability-zone - The Availability Zone in which the Elastic GPU resides. // - // * elastic-gpu-health - The status of the Elastic Graphics accelerator - // (OK | IMPAIRED). + // * elastic-gpu-health - The status of the Elastic GPU (OK | IMPAIRED). // - // * elastic-gpu-state - The state of the Elastic Graphics accelerator (ATTACHED). + // * elastic-gpu-state - The state of the Elastic GPU (ATTACHED). // - // * elastic-gpu-type - The type of Elastic Graphics accelerator; for example, - // eg1.medium. + // * elastic-gpu-type - The type of Elastic GPU; for example, eg1.medium. // - // * instance-id - The ID of the instance to which the Elastic Graphics accelerator - // is associated. + // * instance-id - The ID of the instance to which the Elastic GPU is associated. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // The maximum number of results to return in a single call. To retrieve the // remaining results, make another call with the returned NextToken value. This // value can be between 5 and 1000. - MaxResults *int64 `min:"10" type:"integer"` + MaxResults *int64 `type:"integer"` // The token to request the next page of results. NextToken *string `type:"string"` @@ -49781,19 +35004,6 @@ func (s DescribeElasticGpusInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeElasticGpusInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeElasticGpusInput"} - if s.MaxResults != nil && *s.MaxResults < 10 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 10)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeElasticGpusInput) SetDryRun(v bool) *DescribeElasticGpusInput { s.DryRun = &v @@ -49827,7 +35037,7 @@ func (s *DescribeElasticGpusInput) SetNextToken(v string) *DescribeElasticGpusIn type DescribeElasticGpusOutput struct { _ struct{} `type:"structure"` - // Information about the Elastic Graphics accelerators. + // Information about the Elastic GPUs. ElasticGpuSet []*ElasticGpus `locationName:"elasticGpuSet" locationNameList:"item" type:"list"` // The total number of items to return. If the total number of items available @@ -49868,10 +35078,11 @@ func (s *DescribeElasticGpusOutput) SetNextToken(v string) *DescribeElasticGpusO return s } +// Contains the parameters for DescribeExportTasks. type DescribeExportTasksInput struct { _ struct{} `type:"structure"` - // The export task IDs. + // One or more export task IDs. ExportTaskIds []*string `locationName:"exportTaskId" locationNameList:"ExportTaskId" type:"list"` } @@ -49891,6 +35102,7 @@ func (s *DescribeExportTasksInput) SetExportTaskIds(v []*string) *DescribeExport return s } +// Contains the output for DescribeExportTasks. type DescribeExportTasksOutput struct { _ struct{} `type:"structure"` @@ -49914,62 +35126,6 @@ func (s *DescribeExportTasksOutput) SetExportTasks(v []*ExportTask) *DescribeExp return s } -// Describes the instances that could not be launched by the fleet. -type DescribeFleetError struct { - _ struct{} `type:"structure"` - - // The error code that indicates why the instance could not be launched. For - // more information about error codes, see Error Codes (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html.html). - ErrorCode *string `locationName:"errorCode" type:"string"` - - // The error message that describes why the instance could not be launched. - // For more information about error messages, see ee Error Codes (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html.html). - ErrorMessage *string `locationName:"errorMessage" type:"string"` - - // The launch templates and overrides that were used for launching the instances. - // Any parameters that you specify in the Overrides override the same parameters - // in the launch template. - LaunchTemplateAndOverrides *LaunchTemplateAndOverridesResponse `locationName:"launchTemplateAndOverrides" type:"structure"` - - // Indicates if the instance that could not be launched was a Spot Instance - // or On-Demand Instance. - Lifecycle *string `locationName:"lifecycle" type:"string" enum:"InstanceLifecycle"` -} - -// String returns the string representation -func (s DescribeFleetError) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeFleetError) GoString() string { - return s.String() -} - -// SetErrorCode sets the ErrorCode field's value. -func (s *DescribeFleetError) SetErrorCode(v string) *DescribeFleetError { - s.ErrorCode = &v - return s -} - -// SetErrorMessage sets the ErrorMessage field's value. -func (s *DescribeFleetError) SetErrorMessage(v string) *DescribeFleetError { - s.ErrorMessage = &v - return s -} - -// SetLaunchTemplateAndOverrides sets the LaunchTemplateAndOverrides field's value. -func (s *DescribeFleetError) SetLaunchTemplateAndOverrides(v *LaunchTemplateAndOverridesResponse) *DescribeFleetError { - s.LaunchTemplateAndOverrides = v - return s -} - -// SetLifecycle sets the Lifecycle field's value. -func (s *DescribeFleetError) SetLifecycle(v string) *DescribeFleetError { - s.Lifecycle = &v - return s -} - type DescribeFleetHistoryInput struct { _ struct{} `type:"structure"` @@ -50134,7 +35290,7 @@ type DescribeFleetInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * instance-type - The instance type. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` @@ -50257,7 +35413,7 @@ type DescribeFleetsInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * activity-status - The progress of the EC2 Fleet ( error | pending-fulfillment // | pending-termination | fulfilled). @@ -50272,7 +35428,7 @@ type DescribeFleetsInput struct { // * replace-unhealthy-instances - Indicates whether EC2 Fleet should replace // unhealthy instances (true | false). // - // * type - The type of request (instant | request | maintain). + // * type - The type of request (request | maintain). Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // The ID of the EC2 Fleets. @@ -50327,69 +35483,6 @@ func (s *DescribeFleetsInput) SetNextToken(v string) *DescribeFleetsInput { return s } -// Describes the instances that were launched by the fleet. -type DescribeFleetsInstances struct { - _ struct{} `type:"structure"` - - // The IDs of the instances. - InstanceIds []*string `locationName:"instanceIds" locationNameList:"item" type:"list"` - - // The instance type. - InstanceType *string `locationName:"instanceType" type:"string" enum:"InstanceType"` - - // The launch templates and overrides that were used for launching the instances. - // Any parameters that you specify in the Overrides override the same parameters - // in the launch template. - LaunchTemplateAndOverrides *LaunchTemplateAndOverridesResponse `locationName:"launchTemplateAndOverrides" type:"structure"` - - // Indicates if the instance that was launched is a Spot Instance or On-Demand - // Instance. - Lifecycle *string `locationName:"lifecycle" type:"string" enum:"InstanceLifecycle"` - - // The value is Windows for Windows instances; otherwise blank. - Platform *string `locationName:"platform" type:"string" enum:"PlatformValues"` -} - -// String returns the string representation -func (s DescribeFleetsInstances) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeFleetsInstances) GoString() string { - return s.String() -} - -// SetInstanceIds sets the InstanceIds field's value. -func (s *DescribeFleetsInstances) SetInstanceIds(v []*string) *DescribeFleetsInstances { - s.InstanceIds = v - return s -} - -// SetInstanceType sets the InstanceType field's value. -func (s *DescribeFleetsInstances) SetInstanceType(v string) *DescribeFleetsInstances { - s.InstanceType = &v - return s -} - -// SetLaunchTemplateAndOverrides sets the LaunchTemplateAndOverrides field's value. -func (s *DescribeFleetsInstances) SetLaunchTemplateAndOverrides(v *LaunchTemplateAndOverridesResponse) *DescribeFleetsInstances { - s.LaunchTemplateAndOverrides = v - return s -} - -// SetLifecycle sets the Lifecycle field's value. -func (s *DescribeFleetsInstances) SetLifecycle(v string) *DescribeFleetsInstances { - s.Lifecycle = &v - return s -} - -// SetPlatform sets the Platform field's value. -func (s *DescribeFleetsInstances) SetPlatform(v string) *DescribeFleetsInstances { - s.Platform = &v - return s -} - type DescribeFleetsOutput struct { _ struct{} `type:"structure"` @@ -50422,6 +35515,7 @@ func (s *DescribeFleetsOutput) SetNextToken(v string) *DescribeFleetsOutput { return s } +// Contains the parameters for DescribeFlowLogs. type DescribeFlowLogsInput struct { _ struct{} `type:"structure"` @@ -50449,15 +35543,16 @@ type DescribeFlowLogsInput struct { Filter []*Filter `locationNameList:"Filter" type:"list"` // One or more flow log IDs. - // - // Constraint: Maximum of 1000 flow log IDs. FlowLogIds []*string `locationName:"FlowLogId" locationNameList:"item" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. + // The maximum number of results to return for the request in a single page. + // The remaining results can be seen by sending another request with the returned + // NextToken value. This value can be between 5 and 1000. If MaxResults is given + // a value larger than 1000, only 1000 results are returned. You cannot specify + // this parameter and the flow log IDs parameter in the same request. MaxResults *int64 `type:"integer"` - // The token for the next page of results. + // The token to retrieve the next page of results. NextToken *string `type:"string"` } @@ -50501,6 +35596,7 @@ func (s *DescribeFlowLogsInput) SetNextToken(v string) *DescribeFlowLogsInput { return s } +// Contains the output of DescribeFlowLogs. type DescribeFlowLogsOutput struct { _ struct{} `type:"structure"` @@ -50630,7 +35726,7 @@ type DescribeFpgaImagesInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * create-time - The creation time of the AFI. // @@ -50662,14 +35758,14 @@ type DescribeFpgaImagesInput struct { // * update-time - The time of the most recent update. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The AFI IDs. + // One or more AFI IDs. FpgaImageIds []*string `locationName:"FpgaImageId" locationNameList:"item" type:"list"` // The maximum number of results to return in a single call. MaxResults *int64 `min:"5" type:"integer"` // The token to retrieve the next page of results. - NextToken *string `type:"string"` + NextToken *string `min:"1" type:"string"` // Filters the AFI by owner. Specify an AWS account ID, self (owner is the sender // of the request), or an AWS owner alias (valid values are amazon | aws-marketplace). @@ -50692,6 +35788,9 @@ func (s *DescribeFpgaImagesInput) Validate() error { if s.MaxResults != nil && *s.MaxResults < 5 { invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } if invalidParams.Len() > 0 { return invalidParams @@ -50738,12 +35837,12 @@ func (s *DescribeFpgaImagesInput) SetOwners(v []*string) *DescribeFpgaImagesInpu type DescribeFpgaImagesOutput struct { _ struct{} `type:"structure"` - // Information about the FPGA images. + // Information about one or more FPGA images. FpgaImages []*FpgaImage `locationName:"fpgaImageSet" locationNameList:"item" type:"list"` // The token to use to retrieve the next page of results. This value is null // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation @@ -50771,7 +35870,7 @@ func (s *DescribeFpgaImagesOutput) SetNextToken(v string) *DescribeFpgaImagesOut type DescribeHostReservationOfferingsInput struct { _ struct{} `type:"structure"` - // The filters. + // One or more filters. // // * instance-family - The instance family of the offering (for example, // m4). @@ -50790,7 +35889,7 @@ type DescribeHostReservationOfferingsInput struct { // The remaining results can be seen by sending another request with the returned // nextToken value. This value can be between 5 and 500. If maxResults is given // a larger value than 500, you receive an error. - MaxResults *int64 `min:"5" type:"integer"` + MaxResults *int64 `type:"integer"` // This is the minimum duration of the reservation you'd like to purchase, specified // in seconds. Reservations are available in one-year and three-year terms. @@ -50816,19 +35915,6 @@ func (s DescribeHostReservationOfferingsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeHostReservationOfferingsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeHostReservationOfferingsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetFilter sets the Filter field's value. func (s *DescribeHostReservationOfferingsInput) SetFilter(v []*Filter) *DescribeHostReservationOfferingsInput { s.Filter = v @@ -50901,7 +35987,7 @@ func (s *DescribeHostReservationOfferingsOutput) SetOfferingSet(v []*HostOfferin type DescribeHostReservationsInput struct { _ struct{} `type:"structure"` - // The filters. + // One or more filters. // // * instance-family - The instance family (for example, m4). // @@ -50909,24 +35995,14 @@ type DescribeHostReservationsInput struct { // // * state - The state of the reservation (payment-pending | payment-failed // | active | retired). - // - // * tag: - The key/value combination of a tag assigned to the resource. - // Use the tag key in the filter name and the tag value as the filter value. - // For example, to find all resources that have a tag with the key Owner - // and the value TeamA, specify tag:Owner for the filter name and TeamA for - // the filter value. - // - // * tag-key - The key of a tag assigned to the resource. Use this filter - // to find all resources assigned a tag with a specific key, regardless of - // the tag value. Filter []*Filter `locationNameList:"Filter" type:"list"` - // The host reservation IDs. + // One or more host reservation IDs. HostReservationIdSet []*string `locationNameList:"item" type:"list"` // The maximum number of results to return for the request in a single page. // The remaining results can be seen by sending another request with the returned - // nextToken value. This value can be between 5 and 500. If maxResults is given + // nextToken value. This value can be between 5 and 500.If maxResults is given // a larger value than 500, you receive an error. MaxResults *int64 `type:"integer"` @@ -51001,10 +36077,11 @@ func (s *DescribeHostReservationsOutput) SetNextToken(v string) *DescribeHostRes return s } +// Contains the parameters for DescribeHosts. type DescribeHostsInput struct { _ struct{} `type:"structure"` - // The filters. + // One or more filters. // // * auto-placement - Whether auto-placement is enabled or disabled (on | // off). @@ -51033,13 +36110,11 @@ type DescribeHostsInput struct { // The maximum number of results to return for the request in a single page. // The remaining results can be seen by sending another request with the returned // nextToken value. This value can be between 5 and 500. If maxResults is given - // a larger value than 500, you receive an error. - // - // You cannot specify this parameter and the host IDs parameter in the same - // request. + // a larger value than 500, you receive an error. You cannot specify this parameter + // and the host IDs parameter in the same request. MaxResults *int64 `locationName:"maxResults" type:"integer"` - // The token to use to retrieve the next page of results. + // The token to retrieve the next page of results. NextToken *string `locationName:"nextToken" type:"string"` } @@ -51077,6 +36152,7 @@ func (s *DescribeHostsInput) SetNextToken(v string) *DescribeHostsInput { return s } +// Contains the output of DescribeHosts. type DescribeHostsOutput struct { _ struct{} `type:"structure"` @@ -51113,10 +36189,10 @@ func (s *DescribeHostsOutput) SetNextToken(v string) *DescribeHostsOutput { type DescribeIamInstanceProfileAssociationsInput struct { _ struct{} `type:"structure"` - // The IAM instance profile associations. + // One or more IAM instance profile associations. AssociationIds []*string `locationName:"AssociationId" locationNameList:"AssociationId" type:"list"` - // The filters. + // One or more filters. // // * instance-id - The ID of the instance. // @@ -51129,7 +36205,7 @@ type DescribeIamInstanceProfileAssociationsInput struct { MaxResults *int64 `min:"5" type:"integer"` // The token to request the next page of results. - NextToken *string `type:"string"` + NextToken *string `min:"1" type:"string"` } // String returns the string representation @@ -51148,6 +36224,9 @@ func (s *DescribeIamInstanceProfileAssociationsInput) Validate() error { if s.MaxResults != nil && *s.MaxResults < 5 { invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } if invalidParams.Len() > 0 { return invalidParams @@ -51182,12 +36261,12 @@ func (s *DescribeIamInstanceProfileAssociationsInput) SetNextToken(v string) *De type DescribeIamInstanceProfileAssociationsOutput struct { _ struct{} `type:"structure"` - // Information about the IAM instance profile associations. + // Information about one or more IAM instance profile associations. IamInstanceProfileAssociations []*IamInstanceProfileAssociation `locationName:"iamInstanceProfileAssociationSet" locationNameList:"item" type:"list"` // The token to use to retrieve the next page of results. This value is null // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation @@ -51212,6 +36291,7 @@ func (s *DescribeIamInstanceProfileAssociationsOutput) SetNextToken(v string) *D return s } +// Contains the parameters for DescribeIdFormat. type DescribeIdFormatInput struct { _ struct{} `type:"structure"` @@ -51241,6 +36321,7 @@ func (s *DescribeIdFormatInput) SetResource(v string) *DescribeIdFormatInput { return s } +// Contains the output of DescribeIdFormat. type DescribeIdFormatOutput struct { _ struct{} `type:"structure"` @@ -51264,6 +36345,7 @@ func (s *DescribeIdFormatOutput) SetStatuses(v []*IdFormat) *DescribeIdFormatOut return s } +// Contains the parameters for DescribeIdentityIdFormat. type DescribeIdentityIdFormatInput struct { _ struct{} `type:"structure"` @@ -51318,6 +36400,7 @@ func (s *DescribeIdentityIdFormatInput) SetResource(v string) *DescribeIdentityI return s } +// Contains the output of DescribeIdentityIdFormat. type DescribeIdentityIdFormatOutput struct { _ struct{} `type:"structure"` @@ -51414,7 +36497,7 @@ func (s *DescribeImageAttributeInput) SetImageId(v string) *DescribeImageAttribu type DescribeImageAttributeOutput struct { _ struct{} `type:"structure"` - // The block device mapping entries. + // One or more block device mapping entries. BlockDeviceMappings []*BlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"` // A description for the AMI. @@ -51426,10 +36509,10 @@ type DescribeImageAttributeOutput struct { // The kernel ID. KernelId *AttributeValue `locationName:"kernel" type:"structure"` - // The launch permissions. + // One or more launch permissions. LaunchPermissions []*LaunchPermission `locationName:"launchPermission" locationNameList:"item" type:"list"` - // The product codes. + // One or more product codes. ProductCodes []*ProductCode `locationName:"productCodes" locationNameList:"item" type:"list"` // The RAM disk ID. @@ -51498,6 +36581,7 @@ func (s *DescribeImageAttributeOutput) SetSriovNetSupport(v *AttributeValue) *De return s } +// Contains the parameters for DescribeImages. type DescribeImagesInput struct { _ struct{} `type:"structure"` @@ -51511,9 +36595,9 @@ type DescribeImagesInput struct { // account ID, self (the sender of the request), or all (public AMIs). ExecutableUsers []*string `locationName:"ExecutableBy" locationNameList:"ExecutableBy" type:"list"` - // The filters. + // One or more filters. // - // * architecture - The image architecture (i386 | x86_64 | arm64). + // * architecture - The image architecture (i386 | x86_64). // // * block-device-mapping.delete-on-termination - A Boolean value that indicates // whether the Amazon EBS volume is deleted on instance termination. @@ -51530,9 +36614,6 @@ type DescribeImagesInput struct { // * block-device-mapping.volume-type - The volume type of the EBS volume // (gp2 | io1 | st1 | sc1 | standard). // - // * block-device-mapping.encrypted - A Boolean that indicates whether the - // EBS volume is encrypted. - // // * description - The description of the image (provided during image creation). // // * ena-support - A Boolean that indicates whether enhanced networking with @@ -51593,7 +36674,7 @@ type DescribeImagesInput struct { // * virtualization-type - The virtualization type (paravirtual | hvm). Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The image IDs. + // One or more image IDs. // // Default: Describes all images available to you. ImageIds []*string `locationName:"ImageId" locationNameList:"ImageId" type:"list"` @@ -51645,10 +36726,11 @@ func (s *DescribeImagesInput) SetOwners(v []*string) *DescribeImagesInput { return s } +// Contains the output of DescribeImages. type DescribeImagesOutput struct { _ struct{} `type:"structure"` - // Information about the images. + // Information about one or more images. Images []*Image `locationName:"imagesSet" locationNameList:"item" type:"list"` } @@ -51668,6 +36750,7 @@ func (s *DescribeImagesOutput) SetImages(v []*Image) *DescribeImagesOutput { return s } +// Contains the parameters for DescribeImportImageTasks. type DescribeImportImageTasksInput struct { _ struct{} `type:"structure"` @@ -51732,6 +36815,7 @@ func (s *DescribeImportImageTasksInput) SetNextToken(v string) *DescribeImportIm return s } +// Contains the output for DescribeImportImageTasks. type DescribeImportImageTasksOutput struct { _ struct{} `type:"structure"` @@ -51766,6 +36850,7 @@ func (s *DescribeImportImageTasksOutput) SetNextToken(v string) *DescribeImportI return s } +// Contains the parameters for DescribeImportSnapshotTasks. type DescribeImportSnapshotTasksInput struct { _ struct{} `type:"structure"` @@ -51775,7 +36860,7 @@ type DescribeImportSnapshotTasksInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. Filters []*Filter `locationNameList:"Filter" type:"list"` // A list of import snapshot task IDs. @@ -51829,6 +36914,7 @@ func (s *DescribeImportSnapshotTasksInput) SetNextToken(v string) *DescribeImpor return s } +// Contains the output for DescribeImportSnapshotTasks. type DescribeImportSnapshotTasksOutput struct { _ struct{} `type:"structure"` @@ -51863,6 +36949,7 @@ func (s *DescribeImportSnapshotTasksOutput) SetNextToken(v string) *DescribeImpo return s } +// Contains the parameters for DescribeInstanceAttribute. type DescribeInstanceAttributeInput struct { _ struct{} `type:"structure"` @@ -52093,12 +37180,12 @@ type DescribeInstanceCreditSpecificationsInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * instance-id - The ID of the instance. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The instance IDs. + // One or more instance IDs. // // Default: Describes all your instances. // @@ -52109,7 +37196,7 @@ type DescribeInstanceCreditSpecificationsInput struct { // remaining results, make another call with the returned NextToken value. This // value can be between 5 and 1000. You cannot specify this parameter and the // instance IDs parameter in the same call. - MaxResults *int64 `min:"5" type:"integer"` + MaxResults *int64 `type:"integer"` // The token to retrieve the next page of results. NextToken *string `type:"string"` @@ -52125,19 +37212,6 @@ func (s DescribeInstanceCreditSpecificationsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeInstanceCreditSpecificationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeInstanceCreditSpecificationsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeInstanceCreditSpecificationsInput) SetDryRun(v bool) *DescribeInstanceCreditSpecificationsInput { s.DryRun = &v @@ -52201,6 +37275,7 @@ func (s *DescribeInstanceCreditSpecificationsOutput) SetNextToken(v string) *Des return s } +// Contains the parameters for DescribeInstanceStatus. type DescribeInstanceStatusInput struct { _ struct{} `type:"structure"` @@ -52210,7 +37285,7 @@ type DescribeInstanceStatusInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * availability-zone - The Availability Zone of the instance. // @@ -52219,18 +37294,12 @@ type DescribeInstanceStatusInput struct { // // * event.description - A description of the event. // - // * event.instance-event-id - The ID of the event whose date and time you - // are modifying. - // // * event.not-after - The latest end time for the scheduled event (for example, // 2014-09-15T17:15:20.000Z). // // * event.not-before - The earliest start time for the scheduled event (for // example, 2014-09-15T17:15:20.000Z). // - // * event.not-before-deadline - The deadline for starting the event (for - // example, 2014-09-15T17:15:20.000Z). - // // * instance-state-code - The code for the instance state, as a 16-bit unsigned // integer. The high byte is used for internal purposes and should be ignored. // The low byte is set based on the state represented. The valid values are @@ -52259,7 +37328,7 @@ type DescribeInstanceStatusInput struct { // Default: false IncludeAllInstances *bool `locationName:"includeAllInstances" type:"boolean"` - // The instance IDs. + // One or more instance IDs. // // Default: Describes all your instances. // @@ -52322,10 +37391,11 @@ func (s *DescribeInstanceStatusInput) SetNextToken(v string) *DescribeInstanceSt return s } +// Contains the output of DescribeInstanceStatus. type DescribeInstanceStatusOutput struct { _ struct{} `type:"structure"` - // Information about the status of the instances. + // One or more instance status descriptions. InstanceStatuses []*InstanceStatus `locationName:"instanceStatusSet" locationNameList:"item" type:"list"` // The token to use to retrieve the next page of results. This value is null @@ -52355,6 +37425,7 @@ func (s *DescribeInstanceStatusOutput) SetNextToken(v string) *DescribeInstanceS return s } +// Contains the parameters for DescribeInstances. type DescribeInstancesInput struct { _ struct{} `type:"structure"` @@ -52364,12 +37435,12 @@ type DescribeInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * affinity - The affinity setting for an instance running on a Dedicated // Host (default | host). // - // * architecture - The instance architecture (i386 | x86_64 | arm64). + // * architecture - The instance architecture (i386 | x86_64). // // * availability-zone - The Availability Zone of the instance. // @@ -52398,10 +37469,6 @@ type DescribeInstancesInput struct { // * group-name - The name of the security group for the instance. EC2-Classic // only. // - // * hibernation-options.configured - A Boolean that indicates whether the - // instance is enabled for hibernation. A value of true means that the instance - // is enabled for hibernation. - // // * host-id - The ID of the Dedicated Host on which the instance is running, // if applicable. // @@ -52432,6 +37499,7 @@ type DescribeInstancesInput struct { // // * instance.group-name - The name of the security group for the instance. // + // // * ip-address - The public IPv4 address of the instance. // // * kernel-id - The kernel ID. @@ -52441,6 +37509,7 @@ type DescribeInstancesInput struct { // * launch-index - When launching multiple instances, this is the index // for the instance in the launch group (for example, 0, 1, 2, and so on). // + // // * launch-time - The time when the instance was launched. // // * monitoring-state - Indicates whether detailed monitoring is enabled @@ -52536,10 +37605,8 @@ type DescribeInstancesInput struct { // // * placement-group-name - The name of the placement group for the instance. // - // * placement-partition-number - The partition in which the instance is - // located. - // - // * platform - The platform. To list only Windows instances, use windows. + // * platform - The platform. Use windows if you have Windows instances; + // otherwise, leave blank. // // * private-dns-name - The private IPv4 DNS name of the instance. // @@ -52603,7 +37670,7 @@ type DescribeInstancesInput struct { // * vpc-id - The ID of the VPC that the instance is running in. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The instance IDs. + // One or more instance IDs. // // Default: Describes all your instances. InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list"` @@ -52658,6 +37725,7 @@ func (s *DescribeInstancesInput) SetNextToken(v string) *DescribeInstancesInput return s } +// Contains the output of DescribeInstances. type DescribeInstancesOutput struct { _ struct{} `type:"structure"` @@ -52665,7 +37733,7 @@ type DescribeInstancesOutput struct { // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` - // Information about the reservations. + // Zero or more reservations. Reservations []*Reservation `locationName:"reservationSet" locationNameList:"item" type:"list"` } @@ -52691,6 +37759,7 @@ func (s *DescribeInstancesOutput) SetReservations(v []*Reservation) *DescribeIns return s } +// Contains the parameters for DescribeInternetGateways. type DescribeInternetGatewaysInput struct { _ struct{} `type:"structure"` @@ -52709,8 +37778,6 @@ type DescribeInternetGatewaysInput struct { // // * internet-gateway-id - The ID of the Internet gateway. // - // * owner-id - The ID of the AWS account that owns the internet gateway. - // // * tag: - The key/value combination of a tag assigned to the resource. // Use the tag key in the filter name and the tag value as the filter value. // For example, to find all resources that have a tag with the key Owner @@ -52726,13 +37793,6 @@ type DescribeInternetGatewaysInput struct { // // Default: Describes all your internet gateways. InternetGatewayIds []*string `locationName:"internetGatewayId" locationNameList:"item" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` } // String returns the string representation @@ -52745,19 +37805,6 @@ func (s DescribeInternetGatewaysInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeInternetGatewaysInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeInternetGatewaysInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeInternetGatewaysInput) SetDryRun(v bool) *DescribeInternetGatewaysInput { s.DryRun = &v @@ -52776,27 +37823,12 @@ func (s *DescribeInternetGatewaysInput) SetInternetGatewayIds(v []*string) *Desc return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeInternetGatewaysInput) SetMaxResults(v int64) *DescribeInternetGatewaysInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeInternetGatewaysInput) SetNextToken(v string) *DescribeInternetGatewaysInput { - s.NextToken = &v - return s -} - +// Contains the output of DescribeInternetGateways. type DescribeInternetGatewaysOutput struct { _ struct{} `type:"structure"` // Information about one or more internet gateways. InternetGateways []*InternetGateway `locationName:"internetGatewaySet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` } // String returns the string representation @@ -52815,12 +37847,7 @@ func (s *DescribeInternetGatewaysOutput) SetInternetGateways(v []*InternetGatewa return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeInternetGatewaysOutput) SetNextToken(v string) *DescribeInternetGatewaysOutput { - s.NextToken = &v - return s -} - +// Contains the parameters for DescribeKeyPairs. type DescribeKeyPairsInput struct { _ struct{} `type:"structure"` @@ -52830,14 +37857,14 @@ type DescribeKeyPairsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * fingerprint - The fingerprint of the key pair. // // * key-name - The name of the key pair. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The key pair names. + // One or more key pair names. // // Default: Describes all your key pairs. KeyNames []*string `locationName:"KeyName" locationNameList:"KeyName" type:"list"` @@ -52871,10 +37898,11 @@ func (s *DescribeKeyPairsInput) SetKeyNames(v []*string) *DescribeKeyPairsInput return s } +// Contains the output of DescribeKeyPairs. type DescribeKeyPairsOutput struct { _ struct{} `type:"structure"` - // Information about the key pairs. + // Information about one or more key pairs. KeyPairs []*KeyPairInfo `locationName:"keySet" locationNameList:"item" type:"list"` } @@ -53094,8 +38122,8 @@ type DescribeLaunchTemplatesInput struct { // The maximum number of results to return in a single call. To retrieve the // remaining results, make another call with the returned NextToken value. This - // value can be between 1 and 200. - MaxResults *int64 `min:"1" type:"integer"` + // value can be between 5 and 1000. + MaxResults *int64 `type:"integer"` // The token to request the next page of results. NextToken *string `type:"string"` @@ -53111,19 +38139,6 @@ func (s DescribeLaunchTemplatesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeLaunchTemplatesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeLaunchTemplatesInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeLaunchTemplatesInput) SetDryRun(v bool) *DescribeLaunchTemplatesInput { s.DryRun = &v @@ -53193,6 +38208,7 @@ func (s *DescribeLaunchTemplatesOutput) SetNextToken(v string) *DescribeLaunchTe return s } +// Contains the parameters for DescribeMovingAddresses. type DescribeMovingAddressesInput struct { _ struct{} `type:"structure"` @@ -53214,9 +38230,9 @@ type DescribeMovingAddressesInput struct { // 1000; if MaxResults is given a value outside of this range, an error is returned. // // Default: If no value is provided, the default is 1000. - MaxResults *int64 `locationName:"maxResults" min:"5" type:"integer"` + MaxResults *int64 `locationName:"maxResults" type:"integer"` - // The token for the next page of results. + // The token to use to retrieve the next page of results. NextToken *string `locationName:"nextToken" type:"string"` // One or more Elastic IP addresses. @@ -53233,19 +38249,6 @@ func (s DescribeMovingAddressesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeMovingAddressesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeMovingAddressesInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeMovingAddressesInput) SetDryRun(v bool) *DescribeMovingAddressesInput { s.DryRun = &v @@ -53276,6 +38279,7 @@ func (s *DescribeMovingAddressesInput) SetPublicIps(v []*string) *DescribeMoving return s } +// Contains the output of DescribeMovingAddresses. type DescribeMovingAddressesOutput struct { _ struct{} `type:"structure"` @@ -53309,6 +38313,7 @@ func (s *DescribeMovingAddressesOutput) SetNextToken(v string) *DescribeMovingAd return s } +// Contains the parameters for DescribeNatGateways. type DescribeNatGatewaysInput struct { _ struct{} `type:"structure"` @@ -53334,14 +38339,18 @@ type DescribeNatGatewaysInput struct { // * vpc-id - The ID of the VPC in which the NAT gateway resides. Filter []*Filter `locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` + // The maximum number of items to return for this request. The request returns + // a token that you can specify in a subsequent call to get the next set of + // results. + // + // Constraint: If the value specified is greater than 1000, we return only 1000 + // items. + MaxResults *int64 `type:"integer"` // One or more NAT gateway IDs. NatGatewayIds []*string `locationName:"NatGatewayId" locationNameList:"item" type:"list"` - // The token for the next page of results. + // The token to retrieve the next page of results. NextToken *string `type:"string"` } @@ -53355,19 +38364,6 @@ func (s DescribeNatGatewaysInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeNatGatewaysInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeNatGatewaysInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetFilter sets the Filter field's value. func (s *DescribeNatGatewaysInput) SetFilter(v []*Filter) *DescribeNatGatewaysInput { s.Filter = v @@ -53392,6 +38388,7 @@ func (s *DescribeNatGatewaysInput) SetNextToken(v string) *DescribeNatGatewaysIn return s } +// Contains the output of DescribeNatGateways. type DescribeNatGatewaysOutput struct { _ struct{} `type:"structure"` @@ -53425,6 +38422,7 @@ func (s *DescribeNatGatewaysOutput) SetNextToken(v string) *DescribeNatGatewaysO return s } +// Contains the parameters for DescribeNetworkAcls. type DescribeNetworkAclsInput struct { _ struct{} `type:"structure"` @@ -53448,6 +38446,8 @@ type DescribeNetworkAclsInput struct { // // * entry.cidr - The IPv4 CIDR range specified in the entry. // + // * entry.egress - Indicates whether the entry applies to egress traffic. + // // * entry.icmp.code - The ICMP code specified in the entry, if any. // // * entry.icmp.type - The ICMP type specified in the entry, if any. @@ -53459,18 +38459,17 @@ type DescribeNetworkAclsInput struct { // // * entry.port-range.to - The end of the port range specified in the entry. // + // // * entry.protocol - The protocol specified in the entry (tcp | udp | icmp // or a protocol number). // // * entry.rule-action - Allows or denies the matching traffic (allow | deny). // // * entry.rule-number - The number of an entry (in other words, rule) in - // the set of ACL entries. + // the ACL's set of entries. // // * network-acl-id - The ID of the network ACL. // - // * owner-id - The ID of the AWS account that owns the network ACL. - // // * tag: - The key/value combination of a tag assigned to the resource. // Use the tag key in the filter name and the tag value as the filter value. // For example, to find all resources that have a tag with the key Owner @@ -53484,17 +38483,10 @@ type DescribeNetworkAclsInput struct { // * vpc-id - The ID of the VPC for the network ACL. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - // One or more network ACL IDs. // // Default: Describes all your network ACLs. NetworkAclIds []*string `locationName:"NetworkAclId" locationNameList:"item" type:"list"` - - // The token for the next page of results. - NextToken *string `type:"string"` } // String returns the string representation @@ -53507,19 +38499,6 @@ func (s DescribeNetworkAclsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeNetworkAclsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeNetworkAclsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeNetworkAclsInput) SetDryRun(v bool) *DescribeNetworkAclsInput { s.DryRun = &v @@ -53532,33 +38511,18 @@ func (s *DescribeNetworkAclsInput) SetFilters(v []*Filter) *DescribeNetworkAclsI return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeNetworkAclsInput) SetMaxResults(v int64) *DescribeNetworkAclsInput { - s.MaxResults = &v - return s -} - // SetNetworkAclIds sets the NetworkAclIds field's value. func (s *DescribeNetworkAclsInput) SetNetworkAclIds(v []*string) *DescribeNetworkAclsInput { s.NetworkAclIds = v return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeNetworkAclsInput) SetNextToken(v string) *DescribeNetworkAclsInput { - s.NextToken = &v - return s -} - +// Contains the output of DescribeNetworkAcls. type DescribeNetworkAclsOutput struct { _ struct{} `type:"structure"` // Information about one or more network ACLs. NetworkAcls []*NetworkAcl `locationName:"networkAclSet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` } // String returns the string representation @@ -53577,12 +38541,6 @@ func (s *DescribeNetworkAclsOutput) SetNetworkAcls(v []*NetworkAcl) *DescribeNet return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeNetworkAclsOutput) SetNextToken(v string) *DescribeNetworkAclsOutput { - s.NextToken = &v - return s -} - // Contains the parameters for DescribeNetworkInterfaceAttribute. type DescribeNetworkInterfaceAttributeInput struct { _ struct{} `type:"structure"` @@ -53726,7 +38684,7 @@ type DescribeNetworkInterfacePermissionsInput struct { // The maximum number of results to return in a single call. To retrieve the // remaining results, make another call with the returned NextToken value. If // this parameter is not specified, up to 50 results are returned by default. - MaxResults *int64 `min:"5" type:"integer"` + MaxResults *int64 `type:"integer"` // One or more network interface permission IDs. NetworkInterfacePermissionIds []*string `locationName:"NetworkInterfacePermissionId" type:"list"` @@ -53745,19 +38703,6 @@ func (s DescribeNetworkInterfacePermissionsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeNetworkInterfacePermissionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeNetworkInterfacePermissionsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetFilters sets the Filters field's value. func (s *DescribeNetworkInterfacePermissionsInput) SetFilters(v []*Filter) *DescribeNetworkInterfacePermissionsInput { s.Filters = v @@ -53907,7 +38852,7 @@ type DescribeNetworkInterfacesInput struct { // managed by an AWS service (for example, AWS Management Console, Auto Scaling, // and so on). // - // * source-dest-check - Indicates whether the network interface performs + // * source-desk-check - Indicates whether the network interface performs // source/destination checking. A value of true means checking is enabled, // and false means checking is disabled. The value must be false for the // network interface to perform network address translation (NAT) in your @@ -53932,18 +38877,10 @@ type DescribeNetworkInterfacesInput struct { // * vpc-id - The ID of the VPC for the network interface. Filters []*Filter `locationName:"filter" locationNameList:"Filter" type:"list"` - // The maximum number of items to return for this request. The request returns - // a token that you can specify in a subsequent call to get the next set of - // results. - MaxResults *int64 `min:"5" type:"integer"` - // One or more network interface IDs. // // Default: Describes all your network interfaces. NetworkInterfaceIds []*string `locationName:"NetworkInterfaceId" locationNameList:"item" type:"list"` - - // The token to retrieve the next page of results. - NextToken *string `type:"string"` } // String returns the string representation @@ -53956,19 +38893,6 @@ func (s DescribeNetworkInterfacesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeNetworkInterfacesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeNetworkInterfacesInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeNetworkInterfacesInput) SetDryRun(v bool) *DescribeNetworkInterfacesInput { s.DryRun = &v @@ -53981,34 +38905,18 @@ func (s *DescribeNetworkInterfacesInput) SetFilters(v []*Filter) *DescribeNetwor return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeNetworkInterfacesInput) SetMaxResults(v int64) *DescribeNetworkInterfacesInput { - s.MaxResults = &v - return s -} - // SetNetworkInterfaceIds sets the NetworkInterfaceIds field's value. func (s *DescribeNetworkInterfacesInput) SetNetworkInterfaceIds(v []*string) *DescribeNetworkInterfacesInput { s.NetworkInterfaceIds = v return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeNetworkInterfacesInput) SetNextToken(v string) *DescribeNetworkInterfacesInput { - s.NextToken = &v - return s -} - // Contains the output of DescribeNetworkInterfaces. type DescribeNetworkInterfacesOutput struct { _ struct{} `type:"structure"` // Information about one or more network interfaces. NetworkInterfaces []*NetworkInterface `locationName:"networkInterfaceSet" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` } // String returns the string representation @@ -54027,12 +38935,7 @@ func (s *DescribeNetworkInterfacesOutput) SetNetworkInterfaces(v []*NetworkInter return s } -// SetNextToken sets the NextToken field's value. -func (s *DescribeNetworkInterfacesOutput) SetNextToken(v string) *DescribeNetworkInterfacesOutput { - s.NextToken = &v - return s -} - +// Contains the parameters for DescribePlacementGroups. type DescribePlacementGroupsInput struct { _ struct{} `type:"structure"` @@ -54042,17 +38945,17 @@ type DescribePlacementGroupsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * group-name - The name of the placement group. // // * state - The state of the placement group (pending | available | deleting // | deleted). // - // * strategy - The strategy of the placement group (cluster | spread | partition). + // * strategy - The strategy of the placement group (cluster | spread). Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The names of the placement groups. + // One or more placement group names. // // Default: Describes all your placement groups, or only those otherwise specified. GroupNames []*string `locationName:"groupName" type:"list"` @@ -54086,10 +38989,11 @@ func (s *DescribePlacementGroupsInput) SetGroupNames(v []*string) *DescribePlace return s } +// Contains the output of DescribePlacementGroups. type DescribePlacementGroupsOutput struct { _ struct{} `type:"structure"` - // Information about the placement groups. + // One or more placement groups. PlacementGroups []*PlacementGroup `locationName:"placementGroupSet" locationNameList:"item" type:"list"` } @@ -54109,6 +39013,7 @@ func (s *DescribePlacementGroupsOutput) SetPlacementGroups(v []*PlacementGroup) return s } +// Contains the parameters for DescribePrefixLists. type DescribePrefixListsInput struct { _ struct{} `type:"structure"` @@ -54125,11 +39030,16 @@ type DescribePrefixListsInput struct { // * prefix-list-name: The name of a prefix list. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. + // The maximum number of items to return for this request. The request returns + // a token that you can specify in a subsequent call to get the next set of + // results. + // + // Constraint: If the value specified is greater than 1000, we return only 1000 + // items. MaxResults *int64 `type:"integer"` - // The token for the next page of results. + // The token for the next set of items to return. (You received this token from + // a prior call.) NextToken *string `type:"string"` // One or more prefix list IDs. @@ -54176,11 +39086,12 @@ func (s *DescribePrefixListsInput) SetPrefixListIds(v []*string) *DescribePrefix return s } +// Contains the output of DescribePrefixLists. type DescribePrefixListsOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. + // The token to use when requesting the next set of items. If there are no additional + // items to return, the string is empty. NextToken *string `locationName:"nextToken" type:"string"` // All available prefix lists. @@ -54220,7 +39131,7 @@ type DescribePrincipalIdFormatInput struct { // The maximum number of results to return in a single call. To retrieve the // remaining results, make another call with the returned NextToken value. - MaxResults *int64 `min:"1" type:"integer"` + MaxResults *int64 `type:"integer"` // The token to request the next page of results. NextToken *string `type:"string"` @@ -54245,19 +39156,6 @@ func (s DescribePrincipalIdFormatInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribePrincipalIdFormatInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribePrincipalIdFormatInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribePrincipalIdFormatInput) SetDryRun(v bool) *DescribePrincipalIdFormatInput { s.DryRun = &v @@ -54315,94 +39213,7 @@ func (s *DescribePrincipalIdFormatOutput) SetPrincipals(v []*PrincipalIdFormat) return s } -type DescribePublicIpv4PoolsInput struct { - _ struct{} `type:"structure"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"1" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The IDs of the address pools. - PoolIds []*string `locationName:"PoolId" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribePublicIpv4PoolsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribePublicIpv4PoolsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribePublicIpv4PoolsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribePublicIpv4PoolsInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribePublicIpv4PoolsInput) SetMaxResults(v int64) *DescribePublicIpv4PoolsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribePublicIpv4PoolsInput) SetNextToken(v string) *DescribePublicIpv4PoolsInput { - s.NextToken = &v - return s -} - -// SetPoolIds sets the PoolIds field's value. -func (s *DescribePublicIpv4PoolsInput) SetPoolIds(v []*string) *DescribePublicIpv4PoolsInput { - s.PoolIds = v - return s -} - -type DescribePublicIpv4PoolsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the address pools. - PublicIpv4Pools []*PublicIpv4Pool `locationName:"publicIpv4PoolSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribePublicIpv4PoolsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribePublicIpv4PoolsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribePublicIpv4PoolsOutput) SetNextToken(v string) *DescribePublicIpv4PoolsOutput { - s.NextToken = &v - return s -} - -// SetPublicIpv4Pools sets the PublicIpv4Pools field's value. -func (s *DescribePublicIpv4PoolsOutput) SetPublicIpv4Pools(v []*PublicIpv4Pool) *DescribePublicIpv4PoolsOutput { - s.PublicIpv4Pools = v - return s -} - +// Contains the parameters for DescribeRegions. type DescribeRegionsInput struct { _ struct{} `type:"structure"` @@ -54412,14 +39223,14 @@ type DescribeRegionsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // - // * endpoint - The endpoint of the Region (for example, ec2.us-east-1.amazonaws.com). + // * endpoint - The endpoint of the region (for example, ec2.us-east-1.amazonaws.com). // - // * region-name - The name of the Region (for example, us-east-1). + // * region-name - The name of the region (for example, us-east-1). Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The names of the Regions. + // The names of one or more regions. RegionNames []*string `locationName:"RegionName" locationNameList:"RegionName" type:"list"` } @@ -54451,10 +39262,11 @@ func (s *DescribeRegionsInput) SetRegionNames(v []*string) *DescribeRegionsInput return s } +// Contains the output of DescribeRegions. type DescribeRegionsOutput struct { _ struct{} `type:"structure"` - // Information about the Regions. + // Information about one or more regions. Regions []*Region `locationName:"regionInfo" locationNameList:"item" type:"list"` } @@ -54681,7 +39493,7 @@ type DescribeReservedInstancesModificationsInput struct { // * modification-result.target-configuration.availability-zone - The Availability // Zone for the new Reserved Instances. // - // * modification-result.target-configuration.instance-count - The number + // * modification-result.target-configuration.instance-count - The number // of new Reserved Instances. // // * modification-result.target-configuration.instance-type - The instance @@ -54809,7 +39621,7 @@ type DescribeReservedInstancesOfferingsInput struct { // SUSE Linux (Amazon VPC) | Red Hat Enterprise Linux | Red Hat Enterprise // Linux (Amazon VPC) | Windows | Windows (Amazon VPC) | Windows with SQL // Server Standard | Windows with SQL Server Standard (Amazon VPC) | Windows - // with SQL Server Web | Windows with SQL Server Web (Amazon VPC) | Windows + // with SQL Server Web | Windows with SQL Server Web (Amazon VPC) | Windows // with SQL Server Enterprise | Windows with SQL Server Enterprise (Amazon // VPC)) // @@ -54835,7 +39647,7 @@ type DescribeReservedInstancesOfferingsInput struct { InstanceTenancy *string `locationName:"instanceTenancy" type:"string" enum:"Tenancy"` // The instance type that the reservation will cover (for example, m1.small). - // For more information, see Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) + // For more information, see Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) // in the Amazon Elastic Compute Cloud User Guide. InstanceType *string `type:"string" enum:"InstanceType"` @@ -55038,6 +39850,7 @@ func (s *DescribeReservedInstancesOutput) SetReservedInstances(v []*ReservedInst return s } +// Contains the parameters for DescribeRouteTables. type DescribeRouteTablesInput struct { _ struct{} `type:"structure"` @@ -55061,8 +39874,6 @@ type DescribeRouteTablesInput struct { // table for the VPC (true | false). Route tables that do not have an association // ID are not returned in the response. // - // * owner-id - The ID of the AWS account that owns the route table. - // // * route-table-id - The ID of the route table. // // * route.destination-cidr-block - The IPv4 CIDR range specified in a route @@ -55084,8 +39895,6 @@ type DescribeRouteTablesInput struct { // // * route.nat-gateway-id - The ID of a NAT gateway. // - // * route.transit-gateway-id - The ID of a transit gateway. - // // * route.origin - Describes how the route was created. CreateRouteTable // indicates that the route was automatically created when the route table // was created; CreateRoute indicates that the route was manually added to @@ -55110,18 +39919,9 @@ type DescribeRouteTablesInput struct { // to find all resources assigned a tag with a specific key, regardless of // the tag value. // - // * transit-gateway-id - The ID of a transit gateway. - // // * vpc-id - The ID of the VPC for the route table. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - // One or more route table IDs. // // Default: Describes all your route tables. @@ -55138,19 +39938,6 @@ func (s DescribeRouteTablesInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeRouteTablesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeRouteTablesInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeRouteTablesInput) SetDryRun(v bool) *DescribeRouteTablesInput { s.DryRun = &v @@ -55163,18 +39950,6 @@ func (s *DescribeRouteTablesInput) SetFilters(v []*Filter) *DescribeRouteTablesI return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeRouteTablesInput) SetMaxResults(v int64) *DescribeRouteTablesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeRouteTablesInput) SetNextToken(v string) *DescribeRouteTablesInput { - s.NextToken = &v - return s -} - // SetRouteTableIds sets the RouteTableIds field's value. func (s *DescribeRouteTablesInput) SetRouteTableIds(v []*string) *DescribeRouteTablesInput { s.RouteTableIds = v @@ -55185,10 +39960,6 @@ func (s *DescribeRouteTablesInput) SetRouteTableIds(v []*string) *DescribeRouteT type DescribeRouteTablesOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - // Information about one or more route tables. RouteTables []*RouteTable `locationName:"routeTableSet" locationNameList:"item" type:"list"` } @@ -55203,12 +39974,6 @@ func (s DescribeRouteTablesOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *DescribeRouteTablesOutput) SetNextToken(v string) *DescribeRouteTablesOutput { - s.NextToken = &v - return s -} - // SetRouteTables sets the RouteTables field's value. func (s *DescribeRouteTablesOutput) SetRouteTables(v []*RouteTable) *DescribeRouteTablesOutput { s.RouteTables = v @@ -55225,7 +39990,7 @@ type DescribeScheduledInstanceAvailabilityInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * availability-zone - The Availability Zone (for example, us-west-2a). // @@ -55244,7 +40009,7 @@ type DescribeScheduledInstanceAvailabilityInput struct { // The maximum number of results to return in a single call. This value can // be between 5 and 300. The default value is 300. To retrieve the remaining // results, make another call with the returned NextToken value. - MaxResults *int64 `min:"5" type:"integer"` + MaxResults *int64 `type:"integer"` // The maximum available duration, in hours. This value must be greater than // MinSlotDurationInHours and less than 1,720. @@ -55281,9 +40046,6 @@ func (s *DescribeScheduledInstanceAvailabilityInput) Validate() error { if s.FirstSlotStartTimeRange == nil { invalidParams.Add(request.NewErrParamRequired("FirstSlotStartTimeRange")) } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } if s.Recurrence == nil { invalidParams.Add(request.NewErrParamRequired("Recurrence")) } @@ -55391,7 +40153,7 @@ type DescribeScheduledInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. + // One or more filters. // // * availability-zone - The Availability Zone (for example, us-west-2a). // @@ -55410,7 +40172,7 @@ type DescribeScheduledInstancesInput struct { // The token for the next set of results. NextToken *string `type:"string"` - // The Scheduled Instance IDs. + // One or more Scheduled Instance IDs. ScheduledInstanceIds []*string `locationName:"ScheduledInstanceId" locationNameList:"ScheduledInstanceId" type:"list"` // The time period for the first schedule to start. @@ -55500,13 +40262,13 @@ func (s *DescribeScheduledInstancesOutput) SetScheduledInstanceSet(v []*Schedule type DescribeSecurityGroupReferencesInput struct { _ struct{} `type:"structure"` - // Checks whether you have the required permissions for the action, without + // Checks whether you have the required permissions for the operation, without // actually making the request, and provides an error response. If you have // the required permissions, the error response is DryRunOperation. Otherwise, // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The IDs of the security groups in your account. + // One or more security group IDs in your account. // // GroupId is a required field GroupId []*string `locationNameList:"item" type:"list" required:"true"` @@ -55570,6 +40332,7 @@ func (s *DescribeSecurityGroupReferencesOutput) SetSecurityGroupReferenceSet(v [ return s } +// Contains the parameters for DescribeSecurityGroups. type DescribeSecurityGroupsInput struct { _ struct{} `type:"structure"` @@ -55579,9 +40342,9 @@ type DescribeSecurityGroupsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. If using multiple filters for rules, the results include security - // groups for which any combination of rules - not necessarily a single rule - // - match all filters. + // One or more filters. If using multiple filters for rules, the results include + // security groups for which any combination of rules - not necessarily a single + // rule - match all filters. // // * description - The description of the security group. // @@ -55658,13 +40421,13 @@ type DescribeSecurityGroupsInput struct { // * vpc-id - The ID of the VPC specified when the security group was created. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The IDs of the security groups. Required for security groups in a nondefault + // One or more security group IDs. Required for security groups in a nondefault // VPC. // // Default: Describes all your security groups. GroupIds []*string `locationName:"GroupId" locationNameList:"groupId" type:"list"` - // [EC2-Classic and default VPC only] The names of the security groups. You + // [EC2-Classic and default VPC only] One or more security group names. You // can specify either the security group name or the security group ID. For // security groups in a nondefault VPC, use the group-name filter to describe // security groups by name. @@ -55676,7 +40439,7 @@ type DescribeSecurityGroupsInput struct { // remaining results, make another request with the returned NextToken value. // This value can be between 5 and 1000. If this parameter is not specified, // then all results are returned. - MaxResults *int64 `min:"5" type:"integer"` + MaxResults *int64 `type:"integer"` // The token to request the next page of results. NextToken *string `type:"string"` @@ -55692,19 +40455,6 @@ func (s DescribeSecurityGroupsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeSecurityGroupsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeSecurityGroupsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeSecurityGroupsInput) SetDryRun(v bool) *DescribeSecurityGroupsInput { s.DryRun = &v @@ -55741,6 +40491,7 @@ func (s *DescribeSecurityGroupsInput) SetNextToken(v string) *DescribeSecurityGr return s } +// Contains the output of DescribeSecurityGroups. type DescribeSecurityGroupsOutput struct { _ struct{} `type:"structure"` @@ -55748,7 +40499,7 @@ type DescribeSecurityGroupsOutput struct { // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` - // Information about the security groups. + // Information about one or more security groups. SecurityGroups []*SecurityGroup `locationName:"securityGroupInfo" locationNameList:"item" type:"list"` } @@ -55843,11 +40594,10 @@ func (s *DescribeSnapshotAttributeInput) SetSnapshotId(v string) *DescribeSnapsh type DescribeSnapshotAttributeOutput struct { _ struct{} `type:"structure"` - // The users and groups that have the permissions for creating volumes from - // the snapshot. + // A list of permissions for creating volumes from the snapshot. CreateVolumePermissions []*CreateVolumePermission `locationName:"createVolumePermission" locationNameList:"item" type:"list"` - // The product codes. + // A list of product codes. ProductCodes []*ProductCode `locationName:"productCodes" locationNameList:"item" type:"list"` // The ID of the EBS snapshot. @@ -55882,6 +40632,7 @@ func (s *DescribeSnapshotAttributeOutput) SetSnapshotId(v string) *DescribeSnaps return s } +// Contains the parameters for DescribeSnapshots. type DescribeSnapshotsInput struct { _ struct{} `type:"structure"` @@ -55891,16 +40642,13 @@ type DescribeSnapshotsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * description - A description of the snapshot. // - // * encrypted - Indicates whether the snapshot is encrypted (true | false) - // - // * owner-alias - Value from an Amazon-maintained list (amazon | self | - // all | aws-marketplace | microsoft) of snapshot owners. Not to be confused - // with the user-configured AWS account alias, which is set from the IAM - // console. + // * owner-alias - Value from an Amazon-maintained list (amazon | aws-marketplace + // | microsoft) of snapshot owners. Not to be confused with the user-configured + // AWS account alias, which is set from the IAM console. // // * owner-id - The ID of the AWS account that owns the snapshot. // @@ -55946,15 +40694,16 @@ type DescribeSnapshotsInput struct { // to return. NextToken *string `type:"string"` - // Describes the snapshots owned by these owners. + // Returns the snapshots owned by the specified owner. Multiple owners can be + // specified. OwnerIds []*string `locationName:"Owner" locationNameList:"Owner" type:"list"` - // The IDs of the AWS accounts that can create volumes from the snapshot. + // One or more AWS accounts IDs that can create volumes from the snapshot. RestorableByUserIds []*string `locationName:"RestorableBy" type:"list"` - // The snapshot IDs. + // One or more snapshot IDs. // - // Default: Describes the snapshots for which you have create volume permissions. + // Default: Describes snapshots for which you have launch permissions. SnapshotIds []*string `locationName:"SnapshotId" locationNameList:"SnapshotId" type:"list"` } @@ -56010,6 +40759,7 @@ func (s *DescribeSnapshotsInput) SetSnapshotIds(v []*string) *DescribeSnapshotsI return s } +// Contains the output of DescribeSnapshots. type DescribeSnapshotsOutput struct { _ struct{} `type:"structure"` @@ -56109,7 +40859,7 @@ type DescribeSpotFleetInstancesInput struct { // The maximum number of results to return in a single call. Specify a value // between 1 and 1000. The default value is 1000. To retrieve the remaining // results, make another call with the returned NextToken value. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + MaxResults *int64 `locationName:"maxResults" type:"integer"` // The token for the next set of results. NextToken *string `locationName:"nextToken" type:"string"` @@ -56133,9 +40883,6 @@ func (s DescribeSpotFleetInstancesInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *DescribeSpotFleetInstancesInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DescribeSpotFleetInstancesInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } if s.SpotFleetRequestId == nil { invalidParams.Add(request.NewErrParamRequired("SpotFleetRequestId")) } @@ -56176,14 +40923,18 @@ type DescribeSpotFleetInstancesOutput struct { // The running instances. This list is refreshed periodically and might be out // of date. - ActiveInstances []*ActiveInstance `locationName:"activeInstanceSet" locationNameList:"item" type:"list"` + // + // ActiveInstances is a required field + ActiveInstances []*ActiveInstance `locationName:"activeInstanceSet" locationNameList:"item" type:"list" required:"true"` // The token required to retrieve the next set of results. This value is null // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` } // String returns the string representation @@ -56230,7 +40981,7 @@ type DescribeSpotFleetRequestHistoryInput struct { // The maximum number of results to return in a single call. Specify a value // between 1 and 1000. The default value is 1000. To retrieve the remaining // results, make another call with the returned NextToken value. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` + MaxResults *int64 `locationName:"maxResults" type:"integer"` // The token for the next set of results. NextToken *string `locationName:"nextToken" type:"string"` @@ -56259,9 +41010,6 @@ func (s DescribeSpotFleetRequestHistoryInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *DescribeSpotFleetRequestHistoryInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "DescribeSpotFleetRequestHistoryInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } if s.SpotFleetRequestId == nil { invalidParams.Add(request.NewErrParamRequired("SpotFleetRequestId")) } @@ -56316,23 +41064,31 @@ type DescribeSpotFleetRequestHistoryOutput struct { _ struct{} `type:"structure"` // Information about the events in the history of the Spot Fleet request. - HistoryRecords []*HistoryRecord `locationName:"historyRecordSet" locationNameList:"item" type:"list"` + // + // HistoryRecords is a required field + HistoryRecords []*HistoryRecord `locationName:"historyRecordSet" locationNameList:"item" type:"list" required:"true"` // The last date and time for the events, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). // All records up to this time were retrieved. // // If nextToken indicates that there are more results, this value is not present. - LastEvaluatedTime *time.Time `locationName:"lastEvaluatedTime" type:"timestamp"` + // + // LastEvaluatedTime is a required field + LastEvaluatedTime *time.Time `locationName:"lastEvaluatedTime" type:"timestamp" required:"true"` // The token required to retrieve the next set of results. This value is null // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` // The starting date and time for the events, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). - StartTime *time.Time `locationName:"startTime" type:"timestamp"` + // + // StartTime is a required field + StartTime *time.Time `locationName:"startTime" type:"timestamp" required:"true"` } // String returns the string representation @@ -56440,7 +41196,9 @@ type DescribeSpotFleetRequestsOutput struct { NextToken *string `locationName:"nextToken" type:"string"` // Information about the configuration of your Spot Fleet. - SpotFleetRequestConfigs []*SpotFleetRequestConfig `locationName:"spotFleetRequestConfigSet" locationNameList:"item" type:"list"` + // + // SpotFleetRequestConfigs is a required field + SpotFleetRequestConfigs []*SpotFleetRequestConfig `locationName:"spotFleetRequestConfigSet" locationNameList:"item" type:"list" required:"true"` } // String returns the string representation @@ -56557,7 +41315,7 @@ type DescribeSpotInstanceRequestsInput struct { // * state - The state of the Spot Instance request (open | active | closed // | cancelled | failed). Spot request status information can help you track // your Amazon EC2 Spot Instance requests. For more information, see Spot - // Request Status (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html) + // Request Status (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html) // in the Amazon EC2 User Guide for Linux Instances. // // * status-code - The short code describing the most recent evaluation of @@ -56583,15 +41341,6 @@ type DescribeSpotInstanceRequestsInput struct { // * valid-until - The end date of the request. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return in a single call. Specify a value - // between 5 and 1000. To retrieve the remaining results, make another call - // with the returned NextToken value. - MaxResults *int64 `type:"integer"` - - // The token to request the next set of results. This value is null when there - // are no more results to return. - NextToken *string `type:"string"` - // One or more Spot Instance request IDs. SpotInstanceRequestIds []*string `locationName:"SpotInstanceRequestId" locationNameList:"SpotInstanceRequestId" type:"list"` } @@ -56618,18 +41367,6 @@ func (s *DescribeSpotInstanceRequestsInput) SetFilters(v []*Filter) *DescribeSpo return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeSpotInstanceRequestsInput) SetMaxResults(v int64) *DescribeSpotInstanceRequestsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeSpotInstanceRequestsInput) SetNextToken(v string) *DescribeSpotInstanceRequestsInput { - s.NextToken = &v - return s -} - // SetSpotInstanceRequestIds sets the SpotInstanceRequestIds field's value. func (s *DescribeSpotInstanceRequestsInput) SetSpotInstanceRequestIds(v []*string) *DescribeSpotInstanceRequestsInput { s.SpotInstanceRequestIds = v @@ -56640,10 +41377,6 @@ func (s *DescribeSpotInstanceRequestsInput) SetSpotInstanceRequestIds(v []*strin type DescribeSpotInstanceRequestsOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next set of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - // One or more Spot Instance requests. SpotInstanceRequests []*SpotInstanceRequest `locationName:"spotInstanceRequestSet" locationNameList:"item" type:"list"` } @@ -56658,12 +41391,6 @@ func (s DescribeSpotInstanceRequestsOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *DescribeSpotInstanceRequestsOutput) SetNextToken(v string) *DescribeSpotInstanceRequestsOutput { - s.NextToken = &v - return s -} - // SetSpotInstanceRequests sets the SpotInstanceRequests field's value. func (s *DescribeSpotInstanceRequestsOutput) SetSpotInstanceRequests(v []*SpotInstanceRequest) *DescribeSpotInstanceRequestsOutput { s.SpotInstanceRequests = v @@ -56826,7 +41553,7 @@ func (s *DescribeSpotPriceHistoryOutput) SetSpotPriceHistory(v []*SpotPrice) *De type DescribeStaleSecurityGroupsInput struct { _ struct{} `type:"structure"` - // Checks whether you have the required permissions for the action, without + // Checks whether you have the required permissions for the operation, without // actually making the request, and provides an error response. If you have // the required permissions, the error response is DryRunOperation. Otherwise, // it is UnauthorizedOperation. @@ -56933,6 +41660,7 @@ func (s *DescribeStaleSecurityGroupsOutput) SetStaleSecurityGroupSet(v []*StaleS return s } +// Contains the parameters for DescribeSubnets. type DescribeSubnetsInput struct { _ struct{} `type:"structure"` @@ -56944,21 +41672,18 @@ type DescribeSubnetsInput struct { // One or more filters. // - // * availability-zone - The Availability Zone for the subnet. You can also - // use availabilityZone as the filter name. - // - // * availability-zone-id - The ID of the Availability Zone for the subnet. - // You can also use availabilityZoneId as the filter name. + // * availabilityZone - The Availability Zone for the subnet. You can also + // use availability-zone as the filter name. // // * available-ip-address-count - The number of IPv4 addresses in the subnet // that are available. // - // * cidr-block - The IPv4 CIDR block of the subnet. The CIDR block you specify + // * cidrBlock - The IPv4 CIDR block of the subnet. The CIDR block you specify // must exactly match the subnet's CIDR block for information to be returned - // for the subnet. You can also use cidr or cidrBlock as the filter names. + // for the subnet. You can also use cidr or cidr-block as the filter names. // - // * default-for-az - Indicates whether this is the default subnet for the - // Availability Zone. You can also use defaultForAz as the filter name. + // * defaultForAz - Indicates whether this is the default subnet for the + // Availability Zone. You can also use default-for-az as the filter name. // // * ipv6-cidr-block-association.ipv6-cidr-block - An IPv6 CIDR block associated // with the subnet. @@ -56969,12 +41694,8 @@ type DescribeSubnetsInput struct { // * ipv6-cidr-block-association.state - The state of an IPv6 CIDR block // associated with the subnet. // - // * owner-id - The ID of the AWS account that owns the subnet. - // // * state - The state of the subnet (pending | available). // - // * subnet-arn - The Amazon Resource Name (ARN) of the subnet. - // // * subnet-id - The ID of the subnet. // // * tag: - The key/value combination of a tag assigned to the resource. @@ -56990,13 +41711,6 @@ type DescribeSubnetsInput struct { // * vpc-id - The ID of the VPC for the subnet. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - // One or more subnet IDs. // // Default: Describes all your subnets. @@ -57013,19 +41727,6 @@ func (s DescribeSubnetsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeSubnetsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeSubnetsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeSubnetsInput) SetDryRun(v bool) *DescribeSubnetsInput { s.DryRun = &v @@ -57038,31 +41739,16 @@ func (s *DescribeSubnetsInput) SetFilters(v []*Filter) *DescribeSubnetsInput { return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeSubnetsInput) SetMaxResults(v int64) *DescribeSubnetsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeSubnetsInput) SetNextToken(v string) *DescribeSubnetsInput { - s.NextToken = &v - return s -} - // SetSubnetIds sets the SubnetIds field's value. func (s *DescribeSubnetsInput) SetSubnetIds(v []*string) *DescribeSubnetsInput { s.SubnetIds = v return s } +// Contains the output of DescribeSubnets. type DescribeSubnetsOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - // Information about one or more subnets. Subnets []*Subnet `locationName:"subnetSet" locationNameList:"item" type:"list"` } @@ -57077,18 +41763,13 @@ func (s DescribeSubnetsOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *DescribeSubnetsOutput) SetNextToken(v string) *DescribeSubnetsOutput { - s.NextToken = &v - return s -} - // SetSubnets sets the Subnets field's value. func (s *DescribeSubnetsOutput) SetSubnets(v []*Subnet) *DescribeSubnetsOutput { s.Subnets = v return s } +// Contains the parameters for DescribeTags. type DescribeTagsInput struct { _ struct{} `type:"structure"` @@ -57098,22 +41779,17 @@ type DescribeTagsInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * key - The tag key. // - // * resource-id - The ID of the resource. + // * resource-id - The resource ID. // - // * resource-type - The resource type (customer-gateway | dedicated-host - // | dhcp-options | elastic-ip | fleet | fpga-image | image | instance | - // host-reservation | internet-gateway | launch-template | natgateway | network-acl - // | network-interface | reserved-instances | route-table | security-group - // | snapshot | spot-instances-request | subnet | volume | vpc | vpc-peering-connection - // | vpn-connection | vpn-gateway). - // - // * tag: - The key/value combination of the tag. For example, specify - // "tag:Owner" for the filter name and "TeamA" for the filter value to find - // resources with the tag "Owner=TeamA". + // * resource-type - The resource type (customer-gateway | dhcp-options | + // elastic-ip | fleet | fpga-image | image | instance | internet-gateway + // | launch-template | natgateway | network-acl | network-interface | reserved-instances + // | route-table | security-group | snapshot | spot-instances-request | subnet + // | volume | vpc | vpc-peering-connection | vpn-connection | vpn-gateway). // // * value - The tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` @@ -57161,6 +41837,7 @@ func (s *DescribeTagsInput) SetNextToken(v string) *DescribeTagsInput { return s } +// Contains the output of DescribeTags. type DescribeTagsOutput struct { _ struct{} `type:"structure"` @@ -57168,7 +41845,7 @@ type DescribeTagsOutput struct { // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` - // The tags. + // A list of tags. Tags []*TagDescription `locationName:"tagSet" locationNameList:"item" type:"list"` } @@ -57194,885 +41871,6 @@ func (s *DescribeTagsOutput) SetTags(v []*TagDescription) *DescribeTagsOutput { return s } -type DescribeTrafficMirrorFiltersInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * description: The Traffic Mirror filter description. - // - // * traffic-mirror-filter-id: The ID of the Traffic Mirror filter. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the Traffic Mirror filter. - TrafficMirrorFilterIds []*string `locationName:"TrafficMirrorFilterId" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorFiltersInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorFiltersInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTrafficMirrorFiltersInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTrafficMirrorFiltersInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTrafficMirrorFiltersInput) SetDryRun(v bool) *DescribeTrafficMirrorFiltersInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTrafficMirrorFiltersInput) SetFilters(v []*Filter) *DescribeTrafficMirrorFiltersInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTrafficMirrorFiltersInput) SetMaxResults(v int64) *DescribeTrafficMirrorFiltersInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorFiltersInput) SetNextToken(v string) *DescribeTrafficMirrorFiltersInput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorFilterIds sets the TrafficMirrorFilterIds field's value. -func (s *DescribeTrafficMirrorFiltersInput) SetTrafficMirrorFilterIds(v []*string) *DescribeTrafficMirrorFiltersInput { - s.TrafficMirrorFilterIds = v - return s -} - -type DescribeTrafficMirrorFiltersOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. The value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about one or more Traffic Mirror filters. - TrafficMirrorFilters []*TrafficMirrorFilter `locationName:"trafficMirrorFilterSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorFiltersOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorFiltersOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorFiltersOutput) SetNextToken(v string) *DescribeTrafficMirrorFiltersOutput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorFilters sets the TrafficMirrorFilters field's value. -func (s *DescribeTrafficMirrorFiltersOutput) SetTrafficMirrorFilters(v []*TrafficMirrorFilter) *DescribeTrafficMirrorFiltersOutput { - s.TrafficMirrorFilters = v - return s -} - -type DescribeTrafficMirrorSessionsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * description: The Traffic Mirror session description. - // - // * network-interface-id: The ID of the Traffic Mirror session network interface. - // - // * owner-id: The ID of the account that owns the Traffic Mirror session. - // - // * packet-length: The assigned number of packets to mirror. - // - // * session-number: The assigned session number. - // - // * traffic-mirror-filter-id: The ID of the Traffic Mirror filter. - // - // * traffic-mirror-session-id: The ID of the Traffic Mirror session. - // - // * traffic-mirror-target-id: The ID of the Traffic Mirror target. - // - // * virtual-network-id: The virtual network ID of the Traffic Mirror session. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the Traffic Mirror session. - TrafficMirrorSessionIds []*string `locationName:"TrafficMirrorSessionId" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorSessionsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorSessionsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTrafficMirrorSessionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTrafficMirrorSessionsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTrafficMirrorSessionsInput) SetDryRun(v bool) *DescribeTrafficMirrorSessionsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTrafficMirrorSessionsInput) SetFilters(v []*Filter) *DescribeTrafficMirrorSessionsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTrafficMirrorSessionsInput) SetMaxResults(v int64) *DescribeTrafficMirrorSessionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorSessionsInput) SetNextToken(v string) *DescribeTrafficMirrorSessionsInput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorSessionIds sets the TrafficMirrorSessionIds field's value. -func (s *DescribeTrafficMirrorSessionsInput) SetTrafficMirrorSessionIds(v []*string) *DescribeTrafficMirrorSessionsInput { - s.TrafficMirrorSessionIds = v - return s -} - -type DescribeTrafficMirrorSessionsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. The value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Describes one or more Traffic Mirror sessions. By default, all Traffic Mirror - // sessions are described. Alternatively, you can filter the results. - TrafficMirrorSessions []*TrafficMirrorSession `locationName:"trafficMirrorSessionSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorSessionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorSessionsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorSessionsOutput) SetNextToken(v string) *DescribeTrafficMirrorSessionsOutput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorSessions sets the TrafficMirrorSessions field's value. -func (s *DescribeTrafficMirrorSessionsOutput) SetTrafficMirrorSessions(v []*TrafficMirrorSession) *DescribeTrafficMirrorSessionsOutput { - s.TrafficMirrorSessions = v - return s -} - -type DescribeTrafficMirrorTargetsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * description: The Traffic Mirror target description. - // - // * network-interface-id: The ID of the Traffic Mirror session network interface. - // - // * network-load-balancer-arn: The Amazon Resource Name (ARN) of the Network - // Load Balancer that is associated with the session. - // - // * owner-id: The ID of the account that owns the Traffic Mirror session. - // - // * traffic-mirror-target-id: The ID of the Traffic Mirror target. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the Traffic Mirror targets. - TrafficMirrorTargetIds []*string `locationName:"TrafficMirrorTargetId" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorTargetsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorTargetsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTrafficMirrorTargetsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTrafficMirrorTargetsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTrafficMirrorTargetsInput) SetDryRun(v bool) *DescribeTrafficMirrorTargetsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTrafficMirrorTargetsInput) SetFilters(v []*Filter) *DescribeTrafficMirrorTargetsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTrafficMirrorTargetsInput) SetMaxResults(v int64) *DescribeTrafficMirrorTargetsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorTargetsInput) SetNextToken(v string) *DescribeTrafficMirrorTargetsInput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorTargetIds sets the TrafficMirrorTargetIds field's value. -func (s *DescribeTrafficMirrorTargetsInput) SetTrafficMirrorTargetIds(v []*string) *DescribeTrafficMirrorTargetsInput { - s.TrafficMirrorTargetIds = v - return s -} - -type DescribeTrafficMirrorTargetsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. The value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about one or more Traffic Mirror targets. - TrafficMirrorTargets []*TrafficMirrorTarget `locationName:"trafficMirrorTargetSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTrafficMirrorTargetsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTrafficMirrorTargetsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTrafficMirrorTargetsOutput) SetNextToken(v string) *DescribeTrafficMirrorTargetsOutput { - s.NextToken = &v - return s -} - -// SetTrafficMirrorTargets sets the TrafficMirrorTargets field's value. -func (s *DescribeTrafficMirrorTargetsOutput) SetTrafficMirrorTargets(v []*TrafficMirrorTarget) *DescribeTrafficMirrorTargetsOutput { - s.TrafficMirrorTargets = v - return s -} - -type DescribeTransitGatewayAttachmentsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * association.state - The state of the association (associating | associated - // | disassociating). - // - // * association.transit-gateway-route-table-id - The ID of the route table - // for the transit gateway. - // - // * resource-id - The ID of the resource. - // - // * resource-owner-id - The ID of the AWS account that owns the resource. - // - // * resource-type - The resource type (vpc | vpn). - // - // * state - The state of the attachment (available | deleted | deleting - // | failed | modifying | pendingAcceptance | pending | rollingBack | rejected - // | rejecting). - // - // * transit-gateway-attachment-id - The ID of the attachment. - // - // * transit-gateway-id - The ID of the transit gateway. - // - // * transit-gateway-owner-id - The ID of the AWS account that owns the transit - // gateway. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The IDs of the attachments. - TransitGatewayAttachmentIds []*string `type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayAttachmentsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayAttachmentsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTransitGatewayAttachmentsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTransitGatewayAttachmentsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTransitGatewayAttachmentsInput) SetDryRun(v bool) *DescribeTransitGatewayAttachmentsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTransitGatewayAttachmentsInput) SetFilters(v []*Filter) *DescribeTransitGatewayAttachmentsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTransitGatewayAttachmentsInput) SetMaxResults(v int64) *DescribeTransitGatewayAttachmentsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayAttachmentsInput) SetNextToken(v string) *DescribeTransitGatewayAttachmentsInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayAttachmentIds sets the TransitGatewayAttachmentIds field's value. -func (s *DescribeTransitGatewayAttachmentsInput) SetTransitGatewayAttachmentIds(v []*string) *DescribeTransitGatewayAttachmentsInput { - s.TransitGatewayAttachmentIds = v - return s -} - -type DescribeTransitGatewayAttachmentsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the attachments. - TransitGatewayAttachments []*TransitGatewayAttachment `locationName:"transitGatewayAttachments" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayAttachmentsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayAttachmentsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayAttachmentsOutput) SetNextToken(v string) *DescribeTransitGatewayAttachmentsOutput { - s.NextToken = &v - return s -} - -// SetTransitGatewayAttachments sets the TransitGatewayAttachments field's value. -func (s *DescribeTransitGatewayAttachmentsOutput) SetTransitGatewayAttachments(v []*TransitGatewayAttachment) *DescribeTransitGatewayAttachmentsOutput { - s.TransitGatewayAttachments = v - return s -} - -type DescribeTransitGatewayRouteTablesInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * default-association-route-table - Indicates whether this is the default - // association route table for the transit gateway (true | false). - // - // * default-propagation-route-table - Indicates whether this is the default - // propagation route table for the transit gateway (true | false). - // - // * state - The state of the attachment (available | deleted | deleting - // | failed | modifying | pendingAcceptance | pending | rollingBack | rejected - // | rejecting). - // - // * transit-gateway-id - The ID of the transit gateway. - // - // * transit-gateway-route-table-id - The ID of the transit gateway route - // table. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The IDs of the transit gateway route tables. - TransitGatewayRouteTableIds []*string `locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayRouteTablesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayRouteTablesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTransitGatewayRouteTablesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTransitGatewayRouteTablesInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTransitGatewayRouteTablesInput) SetDryRun(v bool) *DescribeTransitGatewayRouteTablesInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTransitGatewayRouteTablesInput) SetFilters(v []*Filter) *DescribeTransitGatewayRouteTablesInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTransitGatewayRouteTablesInput) SetMaxResults(v int64) *DescribeTransitGatewayRouteTablesInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayRouteTablesInput) SetNextToken(v string) *DescribeTransitGatewayRouteTablesInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayRouteTableIds sets the TransitGatewayRouteTableIds field's value. -func (s *DescribeTransitGatewayRouteTablesInput) SetTransitGatewayRouteTableIds(v []*string) *DescribeTransitGatewayRouteTablesInput { - s.TransitGatewayRouteTableIds = v - return s -} - -type DescribeTransitGatewayRouteTablesOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the transit gateway route tables. - TransitGatewayRouteTables []*TransitGatewayRouteTable `locationName:"transitGatewayRouteTables" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayRouteTablesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayRouteTablesOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayRouteTablesOutput) SetNextToken(v string) *DescribeTransitGatewayRouteTablesOutput { - s.NextToken = &v - return s -} - -// SetTransitGatewayRouteTables sets the TransitGatewayRouteTables field's value. -func (s *DescribeTransitGatewayRouteTablesOutput) SetTransitGatewayRouteTables(v []*TransitGatewayRouteTable) *DescribeTransitGatewayRouteTablesOutput { - s.TransitGatewayRouteTables = v - return s -} - -type DescribeTransitGatewayVpcAttachmentsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * state - The state of the attachment (available | deleted | deleting - // | failed | modifying | pendingAcceptance | pending | rollingBack | rejected - // | rejecting). - // - // * transit-gateway-attachment-id - The ID of the attachment. - // - // * transit-gateway-id - The ID of the transit gateway. - // - // * vpc-id - The ID of the VPC. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The IDs of the attachments. - TransitGatewayAttachmentIds []*string `type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayVpcAttachmentsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayVpcAttachmentsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTransitGatewayVpcAttachmentsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTransitGatewayVpcAttachmentsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTransitGatewayVpcAttachmentsInput) SetDryRun(v bool) *DescribeTransitGatewayVpcAttachmentsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTransitGatewayVpcAttachmentsInput) SetFilters(v []*Filter) *DescribeTransitGatewayVpcAttachmentsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTransitGatewayVpcAttachmentsInput) SetMaxResults(v int64) *DescribeTransitGatewayVpcAttachmentsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayVpcAttachmentsInput) SetNextToken(v string) *DescribeTransitGatewayVpcAttachmentsInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayAttachmentIds sets the TransitGatewayAttachmentIds field's value. -func (s *DescribeTransitGatewayVpcAttachmentsInput) SetTransitGatewayAttachmentIds(v []*string) *DescribeTransitGatewayVpcAttachmentsInput { - s.TransitGatewayAttachmentIds = v - return s -} - -type DescribeTransitGatewayVpcAttachmentsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the VPC attachments. - TransitGatewayVpcAttachments []*TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachments" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewayVpcAttachmentsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewayVpcAttachmentsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewayVpcAttachmentsOutput) SetNextToken(v string) *DescribeTransitGatewayVpcAttachmentsOutput { - s.NextToken = &v - return s -} - -// SetTransitGatewayVpcAttachments sets the TransitGatewayVpcAttachments field's value. -func (s *DescribeTransitGatewayVpcAttachmentsOutput) SetTransitGatewayVpcAttachments(v []*TransitGatewayVpcAttachment) *DescribeTransitGatewayVpcAttachmentsOutput { - s.TransitGatewayVpcAttachments = v - return s -} - -type DescribeTransitGatewaysInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * options.propagation-default-route-table-id - The ID of the default propagation - // route table. - // - // * options.amazon-side-asn - The private ASN for the Amazon side of a BGP - // session. - // - // * options.association-default-route-table-id - The ID of the default association - // route table. - // - // * options.auto-accept-shared-attachments - Indicates whether there is - // automatic acceptance of attachment requests (enable | disable). - // - // * options.default-route-table-association - Indicates whether resource - // attachments are automatically associated with the default association - // route table (enable | disable). - // - // * options.default-route-table-propagation - Indicates whether resource - // attachments automatically propagate routes to the default propagation - // route table (enable | disable). - // - // * options.dns-support - Indicates whether DNS support is enabled (enable - // | disable). - // - // * options.vpn-ecmp-support - Indicates whether Equal Cost Multipath Protocol - // support is enabled (enable | disable). - // - // * owner-id - The ID of the AWS account that owns the transit gateway. - // - // * state - The state of the attachment (available | deleted | deleting - // | failed | modifying | pendingAcceptance | pending | rollingBack | rejected - // | rejecting). - // - // * transit-gateway-id - The ID of the transit gateway. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The IDs of the transit gateways. - TransitGatewayIds []*string `locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewaysInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewaysInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeTransitGatewaysInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeTransitGatewaysInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DescribeTransitGatewaysInput) SetDryRun(v bool) *DescribeTransitGatewaysInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *DescribeTransitGatewaysInput) SetFilters(v []*Filter) *DescribeTransitGatewaysInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeTransitGatewaysInput) SetMaxResults(v int64) *DescribeTransitGatewaysInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewaysInput) SetNextToken(v string) *DescribeTransitGatewaysInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayIds sets the TransitGatewayIds field's value. -func (s *DescribeTransitGatewaysInput) SetTransitGatewayIds(v []*string) *DescribeTransitGatewaysInput { - s.TransitGatewayIds = v - return s -} - -type DescribeTransitGatewaysOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the transit gateways. - TransitGateways []*TransitGateway `locationName:"transitGatewaySet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s DescribeTransitGatewaysOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DescribeTransitGatewaysOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeTransitGatewaysOutput) SetNextToken(v string) *DescribeTransitGatewaysOutput { - s.NextToken = &v - return s -} - -// SetTransitGateways sets the TransitGateways field's value. -func (s *DescribeTransitGatewaysOutput) SetTransitGateways(v []*TransitGateway) *DescribeTransitGatewaysOutput { - s.TransitGateways = v - return s -} - // Contains the parameters for DescribeVolumeAttribute. type DescribeVolumeAttributeInput struct { _ struct{} `type:"structure"` @@ -58180,6 +41978,7 @@ func (s *DescribeVolumeAttributeOutput) SetVolumeId(v string) *DescribeVolumeAtt return s } +// Contains the parameters for DescribeVolumeStatus. type DescribeVolumeStatusInput struct { _ struct{} `type:"structure"` @@ -58189,7 +41988,7 @@ type DescribeVolumeStatusInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * action.code - The action code for the event (for example, enable-volume-io). // @@ -58238,7 +42037,7 @@ type DescribeVolumeStatusInput struct { // more results to return. NextToken *string `type:"string"` - // The IDs of the volumes. + // One or more volume IDs. // // Default: Describes all your volumes. VolumeIds []*string `locationName:"VolumeId" locationNameList:"VolumeId" type:"list"` @@ -58284,6 +42083,7 @@ func (s *DescribeVolumeStatusInput) SetVolumeIds(v []*string) *DescribeVolumeSta return s } +// Contains the output of DescribeVolumeStatus. type DescribeVolumeStatusOutput struct { _ struct{} `type:"structure"` @@ -58291,7 +42091,7 @@ type DescribeVolumeStatusOutput struct { // when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` - // Information about the status of the volumes. + // A list of volumes. VolumeStatuses []*VolumeStatusItem `locationName:"volumeStatusSet" locationNameList:"item" type:"list"` } @@ -58317,6 +42117,7 @@ func (s *DescribeVolumeStatusOutput) SetVolumeStatuses(v []*VolumeStatusItem) *D return s } +// Contains the parameters for DescribeVolumes. type DescribeVolumesInput struct { _ struct{} `type:"structure"` @@ -58326,7 +42127,7 @@ type DescribeVolumesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The filters. + // One or more filters. // // * attachment.attach-time - The time stamp when the attachment initiated. // @@ -58345,7 +42146,7 @@ type DescribeVolumesInput struct { // // * create-time - The time stamp when the volume was created. // - // * encrypted - Indicates whether the volume is encrypted (true | false) + // * encrypted - The encryption status of the volume. // // * size - The size of the volume, in GiB. // @@ -58388,7 +42189,7 @@ type DescribeVolumesInput struct { // NextToken value. This value is null when there are no more results to return. NextToken *string `locationName:"nextToken" type:"string"` - // The volume IDs. + // One or more volume IDs. VolumeIds []*string `locationName:"VolumeId" locationNameList:"VolumeId" type:"list"` } @@ -58441,7 +42242,7 @@ type DescribeVolumesModificationsInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The filters. Supported filters: volume-id, modification-state, target-size, + // One or more filters. Supported filters: volume-id, modification-state, target-size, // target-iops, target-volume-type, original-size, original-iops, original-volume-type, // start-time. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` @@ -58453,7 +42254,7 @@ type DescribeVolumesModificationsInput struct { // The nextToken value returned by a previous paginated request. NextToken *string `type:"string"` - // The IDs of the volumes for which in-progress modifications will be described. + // One or more volume IDs for which in-progress modifications will be described. VolumeIds []*string `locationName:"VolumeId" locationNameList:"VolumeId" type:"list"` } @@ -58503,7 +42304,7 @@ type DescribeVolumesModificationsOutput struct { // Token for pagination, null if there are no more results NextToken *string `locationName:"nextToken" type:"string"` - // Information about the volume modifications. + // A list of returned VolumeModification objects. VolumesModifications []*VolumeModification `locationName:"volumeModificationSet" locationNameList:"item" type:"list"` } @@ -58529,6 +42330,7 @@ func (s *DescribeVolumesModificationsOutput) SetVolumesModifications(v []*Volume return s } +// Contains the output of DescribeVolumes. type DescribeVolumesOutput struct { _ struct{} `type:"structure"` @@ -58564,6 +42366,7 @@ func (s *DescribeVolumesOutput) SetVolumes(v []*Volume) *DescribeVolumesOutput { return s } +// Contains the parameters for DescribeVpcAttribute. type DescribeVpcAttributeInput struct { _ struct{} `type:"structure"` @@ -58628,6 +42431,7 @@ func (s *DescribeVpcAttributeInput) SetVpcId(v string) *DescribeVpcAttributeInpu return s } +// Contains the output of DescribeVpcAttribute. type DescribeVpcAttributeOutput struct { _ struct{} `type:"structure"` @@ -58673,14 +42477,17 @@ func (s *DescribeVpcAttributeOutput) SetVpcId(v string) *DescribeVpcAttributeOut return s } +// Contains the parameters for DescribeVpcClassicLinkDnsSupport. type DescribeVpcClassicLinkDnsSupportInput struct { _ struct{} `type:"structure"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. + // The maximum number of items to return for this request. The request returns + // a token that you can specify in a subsequent call to get the next set of + // results. MaxResults *int64 `locationName:"maxResults" min:"5" type:"integer"` - // The token for the next page of results. + // The token for the next set of items to return. (You received this token from + // a prior call.) NextToken *string `locationName:"nextToken" min:"1" type:"string"` // One or more VPC IDs. @@ -58731,11 +42538,11 @@ func (s *DescribeVpcClassicLinkDnsSupportInput) SetVpcIds(v []*string) *Describe return s } +// Contains the output of DescribeVpcClassicLinkDnsSupport. type DescribeVpcClassicLinkDnsSupportOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. + // The token to use when requesting the next set of items. NextToken *string `locationName:"nextToken" min:"1" type:"string"` // Information about the ClassicLink DNS support status of the VPCs. @@ -58764,6 +42571,7 @@ func (s *DescribeVpcClassicLinkDnsSupportOutput) SetVpcs(v []*ClassicLinkDnsSupp return s } +// Contains the parameters for DescribeVpcClassicLink. type DescribeVpcClassicLinkInput struct { _ struct{} `type:"structure"` @@ -58821,6 +42629,7 @@ func (s *DescribeVpcClassicLinkInput) SetVpcIds(v []*string) *DescribeVpcClassic return s } +// Contains the output of DescribeVpcClassicLink. type DescribeVpcClassicLinkOutput struct { _ struct{} `type:"structure"` @@ -59069,16 +42878,6 @@ type DescribeVpcEndpointServiceConfigurationsInput struct { // // * service-state - The state of the service (Pending | Available | Deleting // | Deleted | Failed). - // - // * tag: - The key/value combination of a tag assigned to the resource. - // Use the tag key in the filter name and the tag value as the filter value. - // For example, to find all resources that have a tag with the key Owner - // and the value TeamA, specify tag:Owner for the filter name and TeamA for - // the filter value. - // - // * tag-key - The key of a tag assigned to the resource. Use this filter - // to find all resources assigned a tag with a specific key, regardless of - // the tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // The maximum number of results to return for the request in a single page. @@ -59300,16 +43099,6 @@ type DescribeVpcEndpointServicesInput struct { // One or more filters. // // * service-name: The name of the service. - // - // * tag: - The key/value combination of a tag assigned to the resource. - // Use the tag key in the filter name and the tag value as the filter value. - // For example, to find all resources that have a tag with the key Owner - // and the value TeamA, specify tag:Owner for the filter name and TeamA for - // the filter value. - // - // * tag-key - The key of a tag assigned to the resource. Use this filter - // to find all resources assigned a tag with a specific key, regardless of - // the tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // The maximum number of items to return for this request. The request returns @@ -59430,16 +43219,6 @@ type DescribeVpcEndpointsInput struct { // // * vpc-endpoint-state: The state of the endpoint. (pending | available // | deleting | deleted) - // - // * tag: - The key/value combination of a tag assigned to the resource. - // Use the tag key in the filter name and the tag value as the filter value. - // For example, to find all resources that have a tag with the key Owner - // and the value TeamA, specify tag:Owner for the filter name and TeamA for - // the filter value. - // - // * tag-key - The key of a tag assigned to the resource. Use this filter - // to find all resources assigned a tag with a specific key, regardless of - // the tag value. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` // The maximum number of items to return for this request. The request returns @@ -59531,6 +43310,7 @@ func (s *DescribeVpcEndpointsOutput) SetVpcEndpoints(v []*VpcEndpoint) *Describe return s } +// Contains the parameters for DescribeVpcPeeringConnections. type DescribeVpcPeeringConnectionsInput struct { _ struct{} `type:"structure"` @@ -59578,13 +43358,6 @@ type DescribeVpcPeeringConnectionsInput struct { // * vpc-peering-connection-id - The ID of the VPC peering connection. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - // One or more VPC peering connection IDs. // // Default: Describes all your VPC peering connections. @@ -59601,19 +43374,6 @@ func (s DescribeVpcPeeringConnectionsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeVpcPeeringConnectionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeVpcPeeringConnectionsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeVpcPeeringConnectionsInput) SetDryRun(v bool) *DescribeVpcPeeringConnectionsInput { s.DryRun = &v @@ -59626,31 +43386,16 @@ func (s *DescribeVpcPeeringConnectionsInput) SetFilters(v []*Filter) *DescribeVp return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeVpcPeeringConnectionsInput) SetMaxResults(v int64) *DescribeVpcPeeringConnectionsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeVpcPeeringConnectionsInput) SetNextToken(v string) *DescribeVpcPeeringConnectionsInput { - s.NextToken = &v - return s -} - // SetVpcPeeringConnectionIds sets the VpcPeeringConnectionIds field's value. func (s *DescribeVpcPeeringConnectionsInput) SetVpcPeeringConnectionIds(v []*string) *DescribeVpcPeeringConnectionsInput { s.VpcPeeringConnectionIds = v return s } +// Contains the output of DescribeVpcPeeringConnections. type DescribeVpcPeeringConnectionsOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - // Information about the VPC peering connections. VpcPeeringConnections []*VpcPeeringConnection `locationName:"vpcPeeringConnectionSet" locationNameList:"item" type:"list"` } @@ -59665,18 +43410,13 @@ func (s DescribeVpcPeeringConnectionsOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *DescribeVpcPeeringConnectionsOutput) SetNextToken(v string) *DescribeVpcPeeringConnectionsOutput { - s.NextToken = &v - return s -} - // SetVpcPeeringConnections sets the VpcPeeringConnections field's value. func (s *DescribeVpcPeeringConnectionsOutput) SetVpcPeeringConnections(v []*VpcPeeringConnection) *DescribeVpcPeeringConnectionsOutput { s.VpcPeeringConnections = v return s } +// Contains the parameters for DescribeVpcs. type DescribeVpcsInput struct { _ struct{} `type:"structure"` @@ -59715,8 +43455,6 @@ type DescribeVpcsInput struct { // // * isDefault - Indicates whether the VPC is the default VPC. // - // * owner-id - The ID of the AWS account that owns the VPC. - // // * state - The state of the VPC (pending | available). // // * tag: - The key/value combination of a tag assigned to the resource. @@ -59732,13 +43470,6 @@ type DescribeVpcsInput struct { // * vpc-id - The ID of the VPC. Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - // One or more VPC IDs. // // Default: Describes all your VPCs. @@ -59755,19 +43486,6 @@ func (s DescribeVpcsInput) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeVpcsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeVpcsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - // SetDryRun sets the DryRun field's value. func (s *DescribeVpcsInput) SetDryRun(v bool) *DescribeVpcsInput { s.DryRun = &v @@ -59780,31 +43498,16 @@ func (s *DescribeVpcsInput) SetFilters(v []*Filter) *DescribeVpcsInput { return s } -// SetMaxResults sets the MaxResults field's value. -func (s *DescribeVpcsInput) SetMaxResults(v int64) *DescribeVpcsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *DescribeVpcsInput) SetNextToken(v string) *DescribeVpcsInput { - s.NextToken = &v - return s -} - // SetVpcIds sets the VpcIds field's value. func (s *DescribeVpcsInput) SetVpcIds(v []*string) *DescribeVpcsInput { s.VpcIds = v return s } +// Contains the output of DescribeVpcs. type DescribeVpcsOutput struct { _ struct{} `type:"structure"` - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - // Information about one or more VPCs. Vpcs []*Vpc `locationName:"vpcSet" locationNameList:"item" type:"list"` } @@ -59819,12 +43522,6 @@ func (s DescribeVpcsOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *DescribeVpcsOutput) SetNextToken(v string) *DescribeVpcsOutput { - s.NextToken = &v - return s -} - // SetVpcs sets the Vpcs field's value. func (s *DescribeVpcsOutput) SetVpcs(v []*Vpc) *DescribeVpcsOutput { s.Vpcs = v @@ -60039,6 +43736,7 @@ func (s *DescribeVpnGatewaysOutput) SetVpnGateways(v []*VpnGateway) *DescribeVpn return s } +// Contains the parameters for DetachClassicLinkVpc. type DetachClassicLinkVpcInput struct { _ struct{} `type:"structure"` @@ -60103,6 +43801,7 @@ func (s *DetachClassicLinkVpcInput) SetVpcId(v string) *DetachClassicLinkVpcInpu return s } +// Contains the output of DetachClassicLinkVpc. type DetachClassicLinkVpcOutput struct { _ struct{} `type:"structure"` @@ -60126,6 +43825,7 @@ func (s *DetachClassicLinkVpcOutput) SetReturn(v bool) *DetachClassicLinkVpcOutp return s } +// Contains the parameters for DetachInternetGateway. type DetachInternetGatewayInput struct { _ struct{} `type:"structure"` @@ -60484,9 +44184,6 @@ type DhcpOptions struct { // The ID of the set of DHCP options. DhcpOptionsId *string `locationName:"dhcpOptionsId" type:"string"` - // The ID of the AWS account that owns the DHCP options set. - OwnerId *string `locationName:"ownerId" type:"string"` - // Any tags assigned to the DHCP options set. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` } @@ -60513,202 +44210,12 @@ func (s *DhcpOptions) SetDhcpOptionsId(v string) *DhcpOptions { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *DhcpOptions) SetOwnerId(v string) *DhcpOptions { - s.OwnerId = &v - return s -} - // SetTags sets the Tags field's value. func (s *DhcpOptions) SetTags(v []*Tag) *DhcpOptions { s.Tags = v return s } -// Describes an Active Directory. -type DirectoryServiceAuthentication struct { - _ struct{} `type:"structure"` - - // The ID of the Active Directory used for authentication. - DirectoryId *string `locationName:"directoryId" type:"string"` -} - -// String returns the string representation -func (s DirectoryServiceAuthentication) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DirectoryServiceAuthentication) GoString() string { - return s.String() -} - -// SetDirectoryId sets the DirectoryId field's value. -func (s *DirectoryServiceAuthentication) SetDirectoryId(v string) *DirectoryServiceAuthentication { - s.DirectoryId = &v - return s -} - -// Describes the Active Directory to be used for client authentication. -type DirectoryServiceAuthenticationRequest struct { - _ struct{} `type:"structure"` - - // The ID of the Active Directory to be used for authentication. - DirectoryId *string `type:"string"` -} - -// String returns the string representation -func (s DirectoryServiceAuthenticationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DirectoryServiceAuthenticationRequest) GoString() string { - return s.String() -} - -// SetDirectoryId sets the DirectoryId field's value. -func (s *DirectoryServiceAuthenticationRequest) SetDirectoryId(v string) *DirectoryServiceAuthenticationRequest { - s.DirectoryId = &v - return s -} - -type DisableEbsEncryptionByDefaultInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s DisableEbsEncryptionByDefaultInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisableEbsEncryptionByDefaultInput) GoString() string { - return s.String() -} - -// SetDryRun sets the DryRun field's value. -func (s *DisableEbsEncryptionByDefaultInput) SetDryRun(v bool) *DisableEbsEncryptionByDefaultInput { - s.DryRun = &v - return s -} - -type DisableEbsEncryptionByDefaultOutput struct { - _ struct{} `type:"structure"` - - // The updated status of encryption by default. - EbsEncryptionByDefault *bool `locationName:"ebsEncryptionByDefault" type:"boolean"` -} - -// String returns the string representation -func (s DisableEbsEncryptionByDefaultOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisableEbsEncryptionByDefaultOutput) GoString() string { - return s.String() -} - -// SetEbsEncryptionByDefault sets the EbsEncryptionByDefault field's value. -func (s *DisableEbsEncryptionByDefaultOutput) SetEbsEncryptionByDefault(v bool) *DisableEbsEncryptionByDefaultOutput { - s.EbsEncryptionByDefault = &v - return s -} - -type DisableTransitGatewayRouteTablePropagationInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` - - // The ID of the propagation route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DisableTransitGatewayRouteTablePropagationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisableTransitGatewayRouteTablePropagationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DisableTransitGatewayRouteTablePropagationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisableTransitGatewayRouteTablePropagationInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DisableTransitGatewayRouteTablePropagationInput) SetDryRun(v bool) *DisableTransitGatewayRouteTablePropagationInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *DisableTransitGatewayRouteTablePropagationInput) SetTransitGatewayAttachmentId(v string) *DisableTransitGatewayRouteTablePropagationInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *DisableTransitGatewayRouteTablePropagationInput) SetTransitGatewayRouteTableId(v string) *DisableTransitGatewayRouteTablePropagationInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type DisableTransitGatewayRouteTablePropagationOutput struct { - _ struct{} `type:"structure"` - - // Information about route propagation. - Propagation *TransitGatewayPropagation `locationName:"propagation" type:"structure"` -} - -// String returns the string representation -func (s DisableTransitGatewayRouteTablePropagationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisableTransitGatewayRouteTablePropagationOutput) GoString() string { - return s.String() -} - -// SetPropagation sets the Propagation field's value. -func (s *DisableTransitGatewayRouteTablePropagationOutput) SetPropagation(v *TransitGatewayPropagation) *DisableTransitGatewayRouteTablePropagationOutput { - s.Propagation = v - return s -} - // Contains the parameters for DisableVgwRoutePropagation. type DisableVgwRoutePropagationInput struct { _ struct{} `type:"structure"` @@ -60776,6 +44283,7 @@ func (s DisableVgwRoutePropagationOutput) GoString() string { return s.String() } +// Contains the parameters for DisableVpcClassicLinkDnsSupport. type DisableVpcClassicLinkDnsSupportInput struct { _ struct{} `type:"structure"` @@ -60799,6 +44307,7 @@ func (s *DisableVpcClassicLinkDnsSupportInput) SetVpcId(v string) *DisableVpcCla return s } +// Contains the output of DisableVpcClassicLinkDnsSupport. type DisableVpcClassicLinkDnsSupportOutput struct { _ struct{} `type:"structure"` @@ -60822,6 +44331,7 @@ func (s *DisableVpcClassicLinkDnsSupportOutput) SetReturn(v bool) *DisableVpcCla return s } +// Contains the parameters for DisableVpcClassicLink. type DisableVpcClassicLinkInput struct { _ struct{} `type:"structure"` @@ -60872,6 +44382,7 @@ func (s *DisableVpcClassicLinkInput) SetVpcId(v string) *DisableVpcClassicLinkIn return s } +// Contains the output of DisableVpcClassicLink. type DisableVpcClassicLinkOutput struct { _ struct{} `type:"structure"` @@ -60895,6 +44406,7 @@ func (s *DisableVpcClassicLinkOutput) SetReturn(v bool) *DisableVpcClassicLinkOu return s } +// Contains the parameters for DisassociateAddress. type DisassociateAddressInput struct { _ struct{} `type:"structure"` @@ -60953,102 +44465,6 @@ func (s DisassociateAddressOutput) GoString() string { return s.String() } -type DisassociateClientVpnTargetNetworkInput struct { - _ struct{} `type:"structure"` - - // The ID of the target network association. - // - // AssociationId is a required field - AssociationId *string `type:"string" required:"true"` - - // The ID of the Client VPN endpoint from which to disassociate the target network. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s DisassociateClientVpnTargetNetworkInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisassociateClientVpnTargetNetworkInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DisassociateClientVpnTargetNetworkInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisassociateClientVpnTargetNetworkInput"} - if s.AssociationId == nil { - invalidParams.Add(request.NewErrParamRequired("AssociationId")) - } - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAssociationId sets the AssociationId field's value. -func (s *DisassociateClientVpnTargetNetworkInput) SetAssociationId(v string) *DisassociateClientVpnTargetNetworkInput { - s.AssociationId = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *DisassociateClientVpnTargetNetworkInput) SetClientVpnEndpointId(v string) *DisassociateClientVpnTargetNetworkInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *DisassociateClientVpnTargetNetworkInput) SetDryRun(v bool) *DisassociateClientVpnTargetNetworkInput { - s.DryRun = &v - return s -} - -type DisassociateClientVpnTargetNetworkOutput struct { - _ struct{} `type:"structure"` - - // The ID of the target network association. - AssociationId *string `locationName:"associationId" type:"string"` - - // The current state of the target network association. - Status *AssociationStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s DisassociateClientVpnTargetNetworkOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisassociateClientVpnTargetNetworkOutput) GoString() string { - return s.String() -} - -// SetAssociationId sets the AssociationId field's value. -func (s *DisassociateClientVpnTargetNetworkOutput) SetAssociationId(v string) *DisassociateClientVpnTargetNetworkOutput { - s.AssociationId = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *DisassociateClientVpnTargetNetworkOutput) SetStatus(v *AssociationStatus) *DisassociateClientVpnTargetNetworkOutput { - s.Status = v - return s -} - type DisassociateIamInstanceProfileInput struct { _ struct{} `type:"structure"` @@ -61110,6 +44526,7 @@ func (s *DisassociateIamInstanceProfileOutput) SetIamInstanceProfileAssociation( return s } +// Contains the parameters for DisassociateRouteTable. type DisassociateRouteTableInput struct { _ struct{} `type:"structure"` @@ -61245,93 +44662,6 @@ func (s *DisassociateSubnetCidrBlockOutput) SetSubnetId(v string) *DisassociateS return s } -type DisassociateTransitGatewayRouteTableInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s DisassociateTransitGatewayRouteTableInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisassociateTransitGatewayRouteTableInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *DisassociateTransitGatewayRouteTableInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisassociateTransitGatewayRouteTableInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *DisassociateTransitGatewayRouteTableInput) SetDryRun(v bool) *DisassociateTransitGatewayRouteTableInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *DisassociateTransitGatewayRouteTableInput) SetTransitGatewayAttachmentId(v string) *DisassociateTransitGatewayRouteTableInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *DisassociateTransitGatewayRouteTableInput) SetTransitGatewayRouteTableId(v string) *DisassociateTransitGatewayRouteTableInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type DisassociateTransitGatewayRouteTableOutput struct { - _ struct{} `type:"structure"` - - // Information about the association. - Association *TransitGatewayAssociation `locationName:"association" type:"structure"` -} - -// String returns the string representation -func (s DisassociateTransitGatewayRouteTableOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DisassociateTransitGatewayRouteTableOutput) GoString() string { - return s.String() -} - -// SetAssociation sets the Association field's value. -func (s *DisassociateTransitGatewayRouteTableOutput) SetAssociation(v *TransitGatewayAssociation) *DisassociateTransitGatewayRouteTableOutput { - s.Association = v - return s -} - type DisassociateVpcCidrBlockInput struct { _ struct{} `type:"structure"` @@ -61486,11 +44816,11 @@ type DiskImageDescription struct { // A presigned URL for the import manifest stored in Amazon S3. For information // about creating a presigned URL for an Amazon S3 object, read the "Query String // Request Authentication Alternative" section of the Authenticating REST Requests - // (https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html) + // (http://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html) // topic in the Amazon Simple Storage Service Developer Guide. // // For information about the import manifest referenced by this API action, - // see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). + // see VM Import Manifest (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). ImportManifestUrl *string `locationName:"importManifestUrl" type:"string"` // The size of the disk image, in GiB. @@ -61548,11 +44878,11 @@ type DiskImageDetail struct { // A presigned URL for the import manifest stored in Amazon S3 and presented // here as an Amazon S3 presigned URL. For information about creating a presigned // URL for an Amazon S3 object, read the "Query String Request Authentication - // Alternative" section of the Authenticating REST Requests (https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html) + // Alternative" section of the Authenticating REST Requests (http://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html) // topic in the Amazon Simple Storage Service Developer Guide. // // For information about the import manifest referenced by this API action, - // see VM Import Manifest (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). + // see VM Import Manifest (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/manifest.html). // // ImportManifestUrl is a required field ImportManifestUrl *string `locationName:"importManifestUrl" type:"string" required:"true"` @@ -61671,42 +45001,6 @@ func (s *DnsEntry) SetHostedZoneId(v string) *DnsEntry { return s } -// Information about the DNS server to be used. -type DnsServersOptionsModifyStructure struct { - _ struct{} `type:"structure"` - - // The IPv4 address range, in CIDR notation, of the DNS servers to be used. - // You can specify up to two DNS servers. Ensure that the DNS servers can be - // reached by the clients. The specified values overwrite the existing values. - CustomDnsServers []*string `locationNameList:"item" type:"list"` - - // Indicates whether DNS servers should be used. Specify False to delete the - // existing DNS servers. - Enabled *bool `type:"boolean"` -} - -// String returns the string representation -func (s DnsServersOptionsModifyStructure) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s DnsServersOptionsModifyStructure) GoString() string { - return s.String() -} - -// SetCustomDnsServers sets the CustomDnsServers field's value. -func (s *DnsServersOptionsModifyStructure) SetCustomDnsServers(v []*string) *DnsServersOptionsModifyStructure { - s.CustomDnsServers = v - return s -} - -// SetEnabled sets the Enabled field's value. -func (s *DnsServersOptionsModifyStructure) SetEnabled(v bool) *DnsServersOptionsModifyStructure { - s.Enabled = &v - return s -} - // Describes a block device for an EBS volume. type EbsBlockDevice struct { _ struct{} `type:"structure"` @@ -61714,44 +45008,34 @@ type EbsBlockDevice struct { // Indicates whether the EBS volume is deleted on instance termination. DeleteOnTermination *bool `locationName:"deleteOnTermination" type:"boolean"` - // Indicates whether the encryption state of an EBS volume is changed while - // being restored from a backing snapshot. The effect of setting the encryption - // state to true depends on the volume origin (new or from a snapshot), starting - // encryption state, ownership, and whether encryption by default is enabled. - // For more information, see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#encryption-parameters) - // in the Amazon Elastic Compute Cloud User Guide. - // - // In no case can you remove encryption from an encrypted volume. - // - // Encrypted volumes can only be attached to instances that support Amazon EBS - // encryption. For more information, see Supported Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#EBSEncryption_supported_instances). + // Indicates whether the EBS volume is encrypted. Encrypted volumes can only + // be attached to instances that support Amazon EBS encryption. If you are creating + // a volume from a snapshot, you can't specify an encryption value. This is + // because only blank volumes can be encrypted on creation. Encrypted *bool `locationName:"encrypted" type:"boolean"` // The number of I/O operations per second (IOPS) that the volume supports. - // For io1 volumes, this represents the number of IOPS that are provisioned - // for the volume. For gp2 volumes, this represents the baseline performance - // of the volume and the rate at which the volume accumulates I/O credits for - // bursting. For more information, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) + // For io1, this represents the number of IOPS that are provisioned for the + // volume. For gp2, this represents the baseline performance of the volume and + // the rate at which the volume accumulates I/O credits for bursting. For more + // information about General Purpose SSD baseline performance, I/O credits, + // and bursting, see Amazon EBS Volume Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) // in the Amazon Elastic Compute Cloud User Guide. // - // Constraints: Range is 100-16,000 IOPS for gp2 volumes and 100 to 64,000IOPS - // for io1 volumes in most Regions. Maximum io1 IOPS of 64,000 is guaranteed - // only on Nitro-based instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html#ec2-nitro-instances). - // Other instance families guarantee performance up to 32,000 IOPS. For more - // information, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) - // in the Amazon Elastic Compute Cloud User Guide. + // Constraint: Range is 100-20000 IOPS for io1 volumes and 100-10000 IOPS for + // gp2 volumes. // // Condition: This parameter is required for requests to create io1 volumes; // it is not used in requests to create gp2, st1, sc1, or standard volumes. Iops *int64 `locationName:"iops" type:"integer"` - // Identifier (key ID, key alias, ID ARN, or alias ARN) for a customer managed - // CMK under which the EBS volume is encrypted. + // Identifier (key ID, key alias, ID ARN, or alias ARN) for a user-managed CMK + // under which the EBS volume is encrypted. // // This parameter is only supported on BlockDeviceMapping objects called by - // RunInstances (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html), - // RequestSpotFleet (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RequestSpotFleet.html), - // and RequestSpotInstances (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RequestSpotInstances.html). + // RunInstances (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html), + // RequestSpotFleet (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RequestSpotFleet.html), + // and RequestSpotInstances (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RequestSpotInstances.html). KmsKeyId *string `type:"string"` // The ID of the snapshot. @@ -61759,17 +45043,17 @@ type EbsBlockDevice struct { // The size of the volume, in GiB. // - // Default: If you're creating the volume from a snapshot and don't specify - // a volume size, the default is the snapshot size. - // // Constraints: 1-16384 for General Purpose SSD (gp2), 4-16384 for Provisioned // IOPS SSD (io1), 500-16384 for Throughput Optimized HDD (st1), 500-16384 for // Cold HDD (sc1), and 1-1024 for Magnetic (standard) volumes. If you specify // a snapshot, the volume size must be equal to or larger than the snapshot // size. + // + // Default: If you're creating the volume from a snapshot and don't specify + // a volume size, the default is the snapshot size. VolumeSize *int64 `locationName:"volumeSize" type:"integer"` - // The volume type. If you set the type to io1, you must also set the Iops property. + // The volume type: gp2, io1, st1, sc1, or standard. // // Default: standard VolumeType *string `locationName:"volumeType" type:"string" enum:"VolumeType"` @@ -61945,21 +45229,20 @@ func (s *EgressOnlyInternetGateway) SetEgressOnlyInternetGatewayId(v string) *Eg return s } -// Describes the association between an instance and an Elastic Graphics accelerator. +// Describes the association between an instance and an Elastic GPU. type ElasticGpuAssociation struct { _ struct{} `type:"structure"` // The ID of the association. ElasticGpuAssociationId *string `locationName:"elasticGpuAssociationId" type:"string"` - // The state of the association between the instance and the Elastic Graphics - // accelerator. + // The state of the association between the instance and the Elastic GPU. ElasticGpuAssociationState *string `locationName:"elasticGpuAssociationState" type:"string"` - // The time the Elastic Graphics accelerator was associated with the instance. + // The time the Elastic GPU was associated with the instance. ElasticGpuAssociationTime *string `locationName:"elasticGpuAssociationTime" type:"string"` - // The ID of the Elastic Graphics accelerator. + // The ID of the Elastic GPU. ElasticGpuId *string `locationName:"elasticGpuId" type:"string"` } @@ -61997,7 +45280,7 @@ func (s *ElasticGpuAssociation) SetElasticGpuId(v string) *ElasticGpuAssociation return s } -// Describes the status of an Elastic Graphics accelerator. +// Describes the status of an Elastic GPU. type ElasticGpuHealth struct { _ struct{} `type:"structure"` @@ -62021,11 +45304,11 @@ func (s *ElasticGpuHealth) SetStatus(v string) *ElasticGpuHealth { return s } -// A specification for an Elastic Graphics accelerator. +// A specification for an Elastic GPU. type ElasticGpuSpecification struct { _ struct{} `type:"structure"` - // The type of Elastic Graphics accelerator. + // The type of Elastic GPU. // // Type is a required field Type *string `type:"string" required:"true"` @@ -62084,26 +45367,26 @@ func (s *ElasticGpuSpecificationResponse) SetType(v string) *ElasticGpuSpecifica return s } -// Describes an Elastic Graphics accelerator. +// Describes an Elastic GPU. type ElasticGpus struct { _ struct{} `type:"structure"` - // The Availability Zone in the which the Elastic Graphics accelerator resides. + // The Availability Zone in the which the Elastic GPU resides. AvailabilityZone *string `locationName:"availabilityZone" type:"string"` - // The status of the Elastic Graphics accelerator. + // The status of the Elastic GPU. ElasticGpuHealth *ElasticGpuHealth `locationName:"elasticGpuHealth" type:"structure"` - // The ID of the Elastic Graphics accelerator. + // The ID of the Elastic GPU. ElasticGpuId *string `locationName:"elasticGpuId" type:"string"` - // The state of the Elastic Graphics accelerator. + // The state of the Elastic GPU. ElasticGpuState *string `locationName:"elasticGpuState" type:"string" enum:"ElasticGpuState"` - // The type of Elastic Graphics accelerator. + // The type of Elastic GPU. ElasticGpuType *string `locationName:"elasticGpuType" type:"string"` - // The ID of the instance to which the Elastic Graphics accelerator is attached. + // The ID of the instance to which the Elastic GPU is attached. InstanceId *string `locationName:"instanceId" type:"string"` } @@ -62153,247 +45436,16 @@ func (s *ElasticGpus) SetInstanceId(v string) *ElasticGpus { return s } -// Describes an elastic inference accelerator. -type ElasticInferenceAccelerator struct { - _ struct{} `type:"structure"` - - // The type of elastic inference accelerator. The possible values are eia1.small, - // eia1.medium, and eia1.large. - // - // Type is a required field - Type *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ElasticInferenceAccelerator) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ElasticInferenceAccelerator) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ElasticInferenceAccelerator) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ElasticInferenceAccelerator"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetType sets the Type field's value. -func (s *ElasticInferenceAccelerator) SetType(v string) *ElasticInferenceAccelerator { - s.Type = &v - return s -} - -// Describes the association between an instance and an elastic inference accelerator. -type ElasticInferenceAcceleratorAssociation struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the elastic inference accelerator. - ElasticInferenceAcceleratorArn *string `locationName:"elasticInferenceAcceleratorArn" type:"string"` - - // The ID of the association. - ElasticInferenceAcceleratorAssociationId *string `locationName:"elasticInferenceAcceleratorAssociationId" type:"string"` - - // The state of the elastic inference accelerator. - ElasticInferenceAcceleratorAssociationState *string `locationName:"elasticInferenceAcceleratorAssociationState" type:"string"` - - // The time at which the elastic inference accelerator is associated with an - // instance. - ElasticInferenceAcceleratorAssociationTime *time.Time `locationName:"elasticInferenceAcceleratorAssociationTime" type:"timestamp"` -} - -// String returns the string representation -func (s ElasticInferenceAcceleratorAssociation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ElasticInferenceAcceleratorAssociation) GoString() string { - return s.String() -} - -// SetElasticInferenceAcceleratorArn sets the ElasticInferenceAcceleratorArn field's value. -func (s *ElasticInferenceAcceleratorAssociation) SetElasticInferenceAcceleratorArn(v string) *ElasticInferenceAcceleratorAssociation { - s.ElasticInferenceAcceleratorArn = &v - return s -} - -// SetElasticInferenceAcceleratorAssociationId sets the ElasticInferenceAcceleratorAssociationId field's value. -func (s *ElasticInferenceAcceleratorAssociation) SetElasticInferenceAcceleratorAssociationId(v string) *ElasticInferenceAcceleratorAssociation { - s.ElasticInferenceAcceleratorAssociationId = &v - return s -} - -// SetElasticInferenceAcceleratorAssociationState sets the ElasticInferenceAcceleratorAssociationState field's value. -func (s *ElasticInferenceAcceleratorAssociation) SetElasticInferenceAcceleratorAssociationState(v string) *ElasticInferenceAcceleratorAssociation { - s.ElasticInferenceAcceleratorAssociationState = &v - return s -} - -// SetElasticInferenceAcceleratorAssociationTime sets the ElasticInferenceAcceleratorAssociationTime field's value. -func (s *ElasticInferenceAcceleratorAssociation) SetElasticInferenceAcceleratorAssociationTime(v time.Time) *ElasticInferenceAcceleratorAssociation { - s.ElasticInferenceAcceleratorAssociationTime = &v - return s -} - -type EnableEbsEncryptionByDefaultInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s EnableEbsEncryptionByDefaultInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s EnableEbsEncryptionByDefaultInput) GoString() string { - return s.String() -} - -// SetDryRun sets the DryRun field's value. -func (s *EnableEbsEncryptionByDefaultInput) SetDryRun(v bool) *EnableEbsEncryptionByDefaultInput { - s.DryRun = &v - return s -} - -type EnableEbsEncryptionByDefaultOutput struct { - _ struct{} `type:"structure"` - - // The updated status of encryption by default. - EbsEncryptionByDefault *bool `locationName:"ebsEncryptionByDefault" type:"boolean"` -} - -// String returns the string representation -func (s EnableEbsEncryptionByDefaultOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s EnableEbsEncryptionByDefaultOutput) GoString() string { - return s.String() -} - -// SetEbsEncryptionByDefault sets the EbsEncryptionByDefault field's value. -func (s *EnableEbsEncryptionByDefaultOutput) SetEbsEncryptionByDefault(v bool) *EnableEbsEncryptionByDefaultOutput { - s.EbsEncryptionByDefault = &v - return s -} - -type EnableTransitGatewayRouteTablePropagationInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` - - // The ID of the propagation route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s EnableTransitGatewayRouteTablePropagationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s EnableTransitGatewayRouteTablePropagationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *EnableTransitGatewayRouteTablePropagationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "EnableTransitGatewayRouteTablePropagationInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *EnableTransitGatewayRouteTablePropagationInput) SetDryRun(v bool) *EnableTransitGatewayRouteTablePropagationInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *EnableTransitGatewayRouteTablePropagationInput) SetTransitGatewayAttachmentId(v string) *EnableTransitGatewayRouteTablePropagationInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *EnableTransitGatewayRouteTablePropagationInput) SetTransitGatewayRouteTableId(v string) *EnableTransitGatewayRouteTablePropagationInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type EnableTransitGatewayRouteTablePropagationOutput struct { - _ struct{} `type:"structure"` - - // Information about route propagation. - Propagation *TransitGatewayPropagation `locationName:"propagation" type:"structure"` -} - -// String returns the string representation -func (s EnableTransitGatewayRouteTablePropagationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s EnableTransitGatewayRouteTablePropagationOutput) GoString() string { - return s.String() -} - -// SetPropagation sets the Propagation field's value. -func (s *EnableTransitGatewayRouteTablePropagationOutput) SetPropagation(v *TransitGatewayPropagation) *EnableTransitGatewayRouteTablePropagationOutput { - s.Propagation = v - return s -} - // Contains the parameters for EnableVgwRoutePropagation. type EnableVgwRoutePropagationInput struct { _ struct{} `type:"structure"` - // The ID of the virtual private gateway that is attached to a VPC. The virtual - // private gateway must be attached to the same VPC that the routing tables - // are associated with. + // The ID of the virtual private gateway. // // GatewayId is a required field GatewayId *string `type:"string" required:"true"` - // The ID of the route table. The routing table must be associated with the - // same VPC that the virtual private gateway is attached to. + // The ID of the route table. // // RouteTableId is a required field RouteTableId *string `type:"string" required:"true"` @@ -62516,6 +45568,7 @@ func (s EnableVolumeIOOutput) GoString() string { return s.String() } +// Contains the parameters for EnableVpcClassicLinkDnsSupport. type EnableVpcClassicLinkDnsSupportInput struct { _ struct{} `type:"structure"` @@ -62539,6 +45592,7 @@ func (s *EnableVpcClassicLinkDnsSupportInput) SetVpcId(v string) *EnableVpcClass return s } +// Contains the output of EnableVpcClassicLinkDnsSupport. type EnableVpcClassicLinkDnsSupportOutput struct { _ struct{} `type:"structure"` @@ -62562,6 +45616,7 @@ func (s *EnableVpcClassicLinkDnsSupportOutput) SetReturn(v bool) *EnableVpcClass return s } +// Contains the parameters for EnableVpcClassicLink. type EnableVpcClassicLinkInput struct { _ struct{} `type:"structure"` @@ -62612,6 +45667,7 @@ func (s *EnableVpcClassicLinkInput) SetVpcId(v string) *EnableVpcClassicLinkInpu return s } +// Contains the output of EnableVpcClassicLink. type EnableVpcClassicLinkOutput struct { _ struct{} `type:"structure"` @@ -62635,7 +45691,7 @@ func (s *EnableVpcClassicLinkOutput) SetReturn(v bool) *EnableVpcClassicLinkOutp return s } -// Describes an EC2 Fleet or Spot Fleet event. +// Describes a Spot Fleet event. type EventInformation struct { _ struct{} `type:"structure"` @@ -62646,8 +45702,12 @@ type EventInformation struct { // // The following are the error events: // - // * iamFleetRoleInvalid - The EC2 Fleet or Spot Fleet did not have the required - // permissions either to launch or terminate an instance. + // * iamFleetRoleInvalid - The Spot Fleet did not have the required permissions + // either to launch or terminate an instance. + // + // * launchSpecTemporarilyBlacklisted - The configuration is not valid and + // several attempts to launch instances have failed. For more information, + // see the description of the event. // // * spotFleetRequestConfigurationInvalid - The configuration is not valid. // For more information, see the description of the event. @@ -62657,35 +45717,33 @@ type EventInformation struct { // // The following are the fleetRequestChange events: // - // * active - The EC2 Fleet or Spot Fleet request has been validated and - // Amazon EC2 is attempting to maintain the target number of running Spot - // Instances. + // * active - The Spot Fleet has been validated and Amazon EC2 is attempting + // to maintain the target number of running Spot Instances. // - // * cancelled - The EC2 Fleet or Spot Fleet request is canceled and has - // no running Spot Instances. The EC2 Fleet or Spot Fleet will be deleted - // two days after its instances were terminated. + // * cancelled - The Spot Fleet is canceled and has no running Spot Instances. + // The Spot Fleet will be deleted two days after its instances were terminated. // - // * cancelled_running - The EC2 Fleet or Spot Fleet request is canceled - // and does not launch additional Spot Instances. Existing Spot Instances - // continue to run until they are interrupted or terminated. + // * cancelled_running - The Spot Fleet is canceled and does not launch additional + // Spot Instances. Existing Spot Instances continue to run until they are + // interrupted or terminated. // - // * cancelled_terminating - The EC2 Fleet or Spot Fleet request is canceled - // and its Spot Instances are terminating. + // * cancelled_terminating - The Spot Fleet is canceled and its Spot Instances + // are terminating. // - // * expired - The EC2 Fleet or Spot Fleet request has expired. A subsequent - // event indicates that the instances were terminated, if the request was - // created with TerminateInstancesWithExpiration set. + // * expired - The Spot Fleet request has expired. A subsequent event indicates + // that the instances were terminated, if the request was created with TerminateInstancesWithExpiration + // set. // - // * modify_in_progress - A request to modify the EC2 Fleet or Spot Fleet - // request was accepted and is in progress. + // * modify_in_progress - A request to modify the Spot Fleet request was + // accepted and is in progress. // - // * modify_successful - The EC2 Fleet or Spot Fleet request was modified. + // * modify_successful - The Spot Fleet request was modified. // // * price_update - The price for a launch configuration was adjusted because // it was too high. This change is permanent. // - // * submitted - The EC2 Fleet or Spot Fleet request is being evaluated and - // Amazon EC2 is preparing to launch the target number of Spot Instances. + // * submitted - The Spot Fleet request is being evaluated and Amazon EC2 + // is preparing to launch the target number of Spot Instances. // // The following are the instanceChange events: // @@ -62695,10 +45753,6 @@ type EventInformation struct { // // The following are the Information events: // - // * launchSpecTemporarilyBlacklisted - The configuration is not valid and - // 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 or the Spot price is above the On-Demand // price. @@ -62740,161 +45794,6 @@ func (s *EventInformation) SetInstanceId(v string) *EventInformation { return s } -type ExportClientVpnClientCertificateRevocationListInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s ExportClientVpnClientCertificateRevocationListInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportClientVpnClientCertificateRevocationListInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ExportClientVpnClientCertificateRevocationListInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ExportClientVpnClientCertificateRevocationListInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ExportClientVpnClientCertificateRevocationListInput) SetClientVpnEndpointId(v string) *ExportClientVpnClientCertificateRevocationListInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ExportClientVpnClientCertificateRevocationListInput) SetDryRun(v bool) *ExportClientVpnClientCertificateRevocationListInput { - s.DryRun = &v - return s -} - -type ExportClientVpnClientCertificateRevocationListOutput struct { - _ struct{} `type:"structure"` - - // Information about the client certificate revocation list. - CertificateRevocationList *string `locationName:"certificateRevocationList" type:"string"` - - // The current state of the client certificate revocation list. - Status *ClientCertificateRevocationListStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s ExportClientVpnClientCertificateRevocationListOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportClientVpnClientCertificateRevocationListOutput) GoString() string { - return s.String() -} - -// SetCertificateRevocationList sets the CertificateRevocationList field's value. -func (s *ExportClientVpnClientCertificateRevocationListOutput) SetCertificateRevocationList(v string) *ExportClientVpnClientCertificateRevocationListOutput { - s.CertificateRevocationList = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *ExportClientVpnClientCertificateRevocationListOutput) SetStatus(v *ClientCertificateRevocationListStatus) *ExportClientVpnClientCertificateRevocationListOutput { - s.Status = v - return s -} - -type ExportClientVpnClientConfigurationInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s ExportClientVpnClientConfigurationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportClientVpnClientConfigurationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ExportClientVpnClientConfigurationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ExportClientVpnClientConfigurationInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ExportClientVpnClientConfigurationInput) SetClientVpnEndpointId(v string) *ExportClientVpnClientConfigurationInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ExportClientVpnClientConfigurationInput) SetDryRun(v bool) *ExportClientVpnClientConfigurationInput { - s.DryRun = &v - return s -} - -type ExportClientVpnClientConfigurationOutput struct { - _ struct{} `type:"structure"` - - // The contents of the Client VPN endpoint configuration file. - ClientConfiguration *string `locationName:"clientConfiguration" type:"string"` -} - -// String returns the string representation -func (s ExportClientVpnClientConfigurationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportClientVpnClientConfigurationOutput) GoString() string { - return s.String() -} - -// SetClientConfiguration sets the ClientConfiguration field's value. -func (s *ExportClientVpnClientConfigurationOutput) SetClientConfiguration(v string) *ExportClientVpnClientConfigurationOutput { - s.ClientConfiguration = &v - return s -} - // Describes an instance export task. type ExportTask struct { _ struct{} `type:"structure"` @@ -63071,128 +45970,6 @@ func (s *ExportToS3TaskSpecification) SetS3Prefix(v string) *ExportToS3TaskSpeci return s } -type ExportTransitGatewayRoutesInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * attachment.transit-gateway-attachment-id - The id of the transit gateway - // attachment. - // - // * attachment.resource-id - The resource id of the transit gateway attachment. - // - // * route-search.exact-match - The exact match of the specified filter. - // - // * route-search.longest-prefix-match - The longest prefix that matches - // the route. - // - // * route-search.subnet-of-match - The routes with a subnet that match the - // specified CIDR filter. - // - // * route-search.supernet-of-match - The routes with a CIDR that encompass - // the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 - // routes in your route table and you specify supernet-of-match as 10.0.1.0/30, - // then the result returns 10.0.1.0/29. - // - // * state - The state of the attachment (available | deleted | deleting - // | failed | modifying | pendingAcceptance | pending | rollingBack | rejected - // | rejecting). - // - // * transit-gateway-route-destination-cidr-block - The CIDR range. - // - // * type - The type of route (active | blackhole). - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The name of the S3 bucket. - // - // S3Bucket is a required field - S3Bucket *string `type:"string" required:"true"` - - // The ID of the route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ExportTransitGatewayRoutesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportTransitGatewayRoutesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ExportTransitGatewayRoutesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ExportTransitGatewayRoutesInput"} - if s.S3Bucket == nil { - invalidParams.Add(request.NewErrParamRequired("S3Bucket")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *ExportTransitGatewayRoutesInput) SetDryRun(v bool) *ExportTransitGatewayRoutesInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *ExportTransitGatewayRoutesInput) SetFilters(v []*Filter) *ExportTransitGatewayRoutesInput { - s.Filters = v - return s -} - -// SetS3Bucket sets the S3Bucket field's value. -func (s *ExportTransitGatewayRoutesInput) SetS3Bucket(v string) *ExportTransitGatewayRoutesInput { - s.S3Bucket = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *ExportTransitGatewayRoutesInput) SetTransitGatewayRouteTableId(v string) *ExportTransitGatewayRoutesInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type ExportTransitGatewayRoutesOutput struct { - _ struct{} `type:"structure"` - - // The URL of the exported file in Amazon S3. For example, s3://bucket_name/VPCTransitGateway/TransitGatewayRouteTables/file_name. - S3Location *string `locationName:"s3Location" type:"string"` -} - -// String returns the string representation -func (s ExportTransitGatewayRoutesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ExportTransitGatewayRoutesOutput) GoString() string { - return s.String() -} - -// SetS3Location sets the S3Location field's value. -func (s *ExportTransitGatewayRoutesOutput) SetS3Location(v string) *ExportTransitGatewayRoutesOutput { - s.S3Location = &v - return s -} - // A filter name and value pair that is used to return a more specific list // of results from a describe operation. Filters can be used to match a set // of resources by specific criteria, such as tags, attributes, or IDs. The @@ -63224,7 +46001,7 @@ type Filter struct { // The name of the filter. Filter names are case-sensitive. Name *string `type:"string"` - // The filter values. Filter values are case-sensitive. + // One or more filter values. Filter values are case-sensitive. Values []*string `locationName:"Value" locationNameList:"item" type:"list"` } @@ -63262,7 +46039,7 @@ type FleetData struct { ActivityStatus *string `locationName:"activityStatus" type:"string" enum:"FleetActivityStatus"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). // // Constraints: Maximum 64 ASCII characters ClientToken *string `locationName:"clientToken" type:"string"` @@ -63270,10 +46047,6 @@ type FleetData struct { // The creation date and time of the EC2 Fleet. CreateTime *time.Time `locationName:"createTime" type:"timestamp"` - // Information about the instances that could not be launched by the fleet. - // Valid only when Type is set to instant. - Errors []*DescribeFleetError `locationName:"errorSet" locationNameList:"item" type:"list"` - // Indicates whether running instances should be terminated if the target capacity // of the EC2 Fleet is decreased below the current size of the EC2 Fleet. ExcessCapacityTerminationPolicy *string `locationName:"excessCapacityTerminationPolicy" type:"string" enum:"FleetExcessCapacityTerminationPolicy"` @@ -63292,10 +46065,6 @@ type FleetData struct { // On-Demand capacity. FulfilledOnDemandCapacity *float64 `locationName:"fulfilledOnDemandCapacity" type:"double"` - // Information about the instances that were launched by the fleet. Valid only - // when Type is set to instant. - Instances []*DescribeFleetsInstances `locationName:"fleetInstanceSet" locationNameList:"item" type:"list"` - // The launch template and overrides. LaunchTemplateConfigs []*FleetLaunchTemplateConfig `locationName:"launchTemplateConfigs" locationNameList:"item" type:"list"` @@ -63370,12 +46139,6 @@ func (s *FleetData) SetCreateTime(v time.Time) *FleetData { return s } -// SetErrors sets the Errors field's value. -func (s *FleetData) SetErrors(v []*DescribeFleetError) *FleetData { - s.Errors = v - return s -} - // SetExcessCapacityTerminationPolicy sets the ExcessCapacityTerminationPolicy field's value. func (s *FleetData) SetExcessCapacityTerminationPolicy(v string) *FleetData { s.ExcessCapacityTerminationPolicy = &v @@ -63406,12 +46169,6 @@ func (s *FleetData) SetFulfilledOnDemandCapacity(v float64) *FleetData { return s } -// SetInstances sets the Instances field's value. -func (s *FleetData) SetInstances(v []*DescribeFleetsInstances) *FleetData { - s.Instances = v - return s -} - // SetLaunchTemplateConfigs sets the LaunchTemplateConfigs field's value. func (s *FleetData) SetLaunchTemplateConfigs(v []*FleetLaunchTemplateConfig) *FleetData { s.LaunchTemplateConfigs = v @@ -63569,9 +46326,6 @@ type FleetLaunchTemplateOverrides struct { // The maximum price per unit hour that you are willing to pay for a Spot Instance. MaxPrice *string `locationName:"maxPrice" type:"string"` - // The location where the instance launched, if applicable. - Placement *PlacementResponse `locationName:"placement" type:"structure"` - // The priority for the launch template override. If AllocationStrategy is set // to prioritized, EC2 Fleet uses priority to determine which launch template // override to use first in fulfilling On-Demand capacity. The highest priority @@ -63615,12 +46369,6 @@ func (s *FleetLaunchTemplateOverrides) SetMaxPrice(v string) *FleetLaunchTemplat return s } -// SetPlacement sets the Placement field's value. -func (s *FleetLaunchTemplateOverrides) SetPlacement(v *PlacementResponse) *FleetLaunchTemplateOverrides { - s.Placement = v - return s -} - // SetPriority sets the Priority field's value. func (s *FleetLaunchTemplateOverrides) SetPriority(v float64) *FleetLaunchTemplateOverrides { s.Priority = &v @@ -63652,9 +46400,6 @@ type FleetLaunchTemplateOverridesRequest struct { // The maximum price per unit hour that you are willing to pay for a Spot Instance. MaxPrice *string `type:"string"` - // The location where the instance launched, if applicable. - Placement *Placement `type:"structure"` - // The priority for the launch template override. If AllocationStrategy is set // to prioritized, EC2 Fleet uses priority to determine which launch template // override to use first in fulfilling On-Demand capacity. The highest priority @@ -63698,12 +46443,6 @@ func (s *FleetLaunchTemplateOverridesRequest) SetMaxPrice(v string) *FleetLaunch return s } -// SetPlacement sets the Placement field's value. -func (s *FleetLaunchTemplateOverridesRequest) SetPlacement(v *Placement) *FleetLaunchTemplateOverridesRequest { - s.Placement = v - return s -} - // SetPriority sets the Priority field's value. func (s *FleetLaunchTemplateOverridesRequest) SetPriority(v float64) *FleetLaunchTemplateOverridesRequest { s.Priority = &v @@ -63734,7 +46473,8 @@ type FleetLaunchTemplateSpecification struct { // or a template ID. LaunchTemplateName *string `locationName:"launchTemplateName" min:"3" type:"string"` - // The version number of the launch template. You must specify a version number. + // The version number. By default, the default version of the launch template + // is used. Version *string `locationName:"version" type:"string"` } @@ -63790,8 +46530,7 @@ type FleetLaunchTemplateSpecificationRequest struct { // The name of the launch template. LaunchTemplateName *string `min:"3" type:"string"` - // The version number of the launch template. Note: This is a required parameter - // and will be updated soon. + // The version number of the launch template. Version *string `type:"string"` } @@ -63968,9 +46707,6 @@ type FpgaImage struct { // The date and time the AFI was created. CreateTime *time.Time `locationName:"createTime" type:"timestamp"` - // Indicates whether data retention support is enabled for the AFI. - DataRetentionSupport *bool `locationName:"dataRetentionSupport" type:"boolean"` - // The description of the AFI. Description *string `locationName:"description" type:"string"` @@ -64027,12 +46763,6 @@ func (s *FpgaImage) SetCreateTime(v time.Time) *FpgaImage { return s } -// SetDataRetentionSupport sets the DataRetentionSupport field's value. -func (s *FpgaImage) SetDataRetentionSupport(v bool) *FpgaImage { - s.DataRetentionSupport = &v - return s -} - // SetDescription sets the Description field's value. func (s *FpgaImage) SetDescription(v string) *FpgaImage { s.Description = &v @@ -64121,13 +46851,13 @@ type FpgaImageAttribute struct { // The ID of the AFI. FpgaImageId *string `locationName:"fpgaImageId" type:"string"` - // The load permissions. + // One or more load permissions. LoadPermissions []*LoadPermission `locationName:"loadPermissions" locationNameList:"item" type:"list"` // The name of the AFI. Name *string `locationName:"name" type:"string"` - // The product codes. + // One or more product codes. ProductCodes []*ProductCode `locationName:"productCodes" locationNameList:"item" type:"list"` } @@ -64213,6 +46943,7 @@ func (s *FpgaImageState) SetMessage(v string) *FpgaImageState { return s } +// Contains the parameters for GetConsoleOutput. type GetConsoleOutputInput struct { _ struct{} `type:"structure"` @@ -64274,6 +47005,7 @@ func (s *GetConsoleOutputInput) SetLatest(v bool) *GetConsoleOutputInput { return s } +// Contains the output of GetConsoleOutput. type GetConsoleOutputOutput struct { _ struct{} `type:"structure"` @@ -64316,6 +47048,7 @@ func (s *GetConsoleOutputOutput) SetTimestamp(v time.Time) *GetConsoleOutputOutp return s } +// Contains the parameters for the request. type GetConsoleScreenshotInput struct { _ struct{} `type:"structure"` @@ -64376,6 +47109,7 @@ func (s *GetConsoleScreenshotInput) SetWakeUp(v bool) *GetConsoleScreenshotInput return s } +// Contains the output of the request. type GetConsoleScreenshotOutput struct { _ struct{} `type:"structure"` @@ -64408,104 +47142,6 @@ func (s *GetConsoleScreenshotOutput) SetInstanceId(v string) *GetConsoleScreensh return s } -type GetEbsDefaultKmsKeyIdInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s GetEbsDefaultKmsKeyIdInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetEbsDefaultKmsKeyIdInput) GoString() string { - return s.String() -} - -// SetDryRun sets the DryRun field's value. -func (s *GetEbsDefaultKmsKeyIdInput) SetDryRun(v bool) *GetEbsDefaultKmsKeyIdInput { - s.DryRun = &v - return s -} - -type GetEbsDefaultKmsKeyIdOutput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the default CMK for encryption by default. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` -} - -// String returns the string representation -func (s GetEbsDefaultKmsKeyIdOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetEbsDefaultKmsKeyIdOutput) GoString() string { - return s.String() -} - -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *GetEbsDefaultKmsKeyIdOutput) SetKmsKeyId(v string) *GetEbsDefaultKmsKeyIdOutput { - s.KmsKeyId = &v - return s -} - -type GetEbsEncryptionByDefaultInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s GetEbsEncryptionByDefaultInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetEbsEncryptionByDefaultInput) GoString() string { - return s.String() -} - -// SetDryRun sets the DryRun field's value. -func (s *GetEbsEncryptionByDefaultInput) SetDryRun(v bool) *GetEbsEncryptionByDefaultInput { - s.DryRun = &v - return s -} - -type GetEbsEncryptionByDefaultOutput struct { - _ struct{} `type:"structure"` - - // Indicates whether encryption by default is enabled. - EbsEncryptionByDefault *bool `locationName:"ebsEncryptionByDefault" type:"boolean"` -} - -// String returns the string representation -func (s GetEbsEncryptionByDefaultOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetEbsEncryptionByDefaultOutput) GoString() string { - return s.String() -} - -// SetEbsEncryptionByDefault sets the EbsEncryptionByDefault field's value. -func (s *GetEbsEncryptionByDefaultOutput) SetEbsEncryptionByDefault(v bool) *GetEbsEncryptionByDefaultOutput { - s.EbsEncryptionByDefault = &v - return s -} - type GetHostReservationPurchasePreviewInput struct { _ struct{} `type:"structure"` @@ -64683,6 +47319,7 @@ func (s *GetLaunchTemplateDataOutput) SetLaunchTemplateData(v *ResponseLaunchTem return s } +// Contains the parameters for GetPasswordData. type GetPasswordDataInput struct { _ struct{} `type:"structure"` @@ -64733,6 +47370,7 @@ func (s *GetPasswordDataInput) SetInstanceId(v string) *GetPasswordDataInput { return s } +// Contains the output of GetPasswordData. type GetPasswordDataOutput struct { _ struct{} `type:"structure"` @@ -64942,363 +47580,6 @@ func (s *GetReservedInstancesExchangeQuoteOutput) SetValidationFailureReason(v s return s } -type GetTransitGatewayAttachmentPropagationsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * transit-gateway-route-table-id - The ID of the transit gateway route - // table. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s GetTransitGatewayAttachmentPropagationsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayAttachmentPropagationsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetTransitGatewayAttachmentPropagationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetTransitGatewayAttachmentPropagationsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *GetTransitGatewayAttachmentPropagationsInput) SetDryRun(v bool) *GetTransitGatewayAttachmentPropagationsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *GetTransitGatewayAttachmentPropagationsInput) SetFilters(v []*Filter) *GetTransitGatewayAttachmentPropagationsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *GetTransitGatewayAttachmentPropagationsInput) SetMaxResults(v int64) *GetTransitGatewayAttachmentPropagationsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayAttachmentPropagationsInput) SetNextToken(v string) *GetTransitGatewayAttachmentPropagationsInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *GetTransitGatewayAttachmentPropagationsInput) SetTransitGatewayAttachmentId(v string) *GetTransitGatewayAttachmentPropagationsInput { - s.TransitGatewayAttachmentId = &v - return s -} - -type GetTransitGatewayAttachmentPropagationsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the propagation route tables. - TransitGatewayAttachmentPropagations []*TransitGatewayAttachmentPropagation `locationName:"transitGatewayAttachmentPropagations" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s GetTransitGatewayAttachmentPropagationsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayAttachmentPropagationsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayAttachmentPropagationsOutput) SetNextToken(v string) *GetTransitGatewayAttachmentPropagationsOutput { - s.NextToken = &v - return s -} - -// SetTransitGatewayAttachmentPropagations sets the TransitGatewayAttachmentPropagations field's value. -func (s *GetTransitGatewayAttachmentPropagationsOutput) SetTransitGatewayAttachmentPropagations(v []*TransitGatewayAttachmentPropagation) *GetTransitGatewayAttachmentPropagationsOutput { - s.TransitGatewayAttachmentPropagations = v - return s -} - -type GetTransitGatewayRouteTableAssociationsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * resource-id - The ID of the resource. - // - // * resource-type - The resource type (vpc | vpn). - // - // * transit-gateway-attachment-id - The ID of the attachment. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s GetTransitGatewayRouteTableAssociationsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayRouteTableAssociationsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetTransitGatewayRouteTableAssociationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetTransitGatewayRouteTableAssociationsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *GetTransitGatewayRouteTableAssociationsInput) SetDryRun(v bool) *GetTransitGatewayRouteTableAssociationsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *GetTransitGatewayRouteTableAssociationsInput) SetFilters(v []*Filter) *GetTransitGatewayRouteTableAssociationsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *GetTransitGatewayRouteTableAssociationsInput) SetMaxResults(v int64) *GetTransitGatewayRouteTableAssociationsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayRouteTableAssociationsInput) SetNextToken(v string) *GetTransitGatewayRouteTableAssociationsInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *GetTransitGatewayRouteTableAssociationsInput) SetTransitGatewayRouteTableId(v string) *GetTransitGatewayRouteTableAssociationsInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type GetTransitGatewayRouteTableAssociationsOutput struct { - _ struct{} `type:"structure"` - - // Information about the associations. - Associations []*TransitGatewayRouteTableAssociation `locationName:"associations" locationNameList:"item" type:"list"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` -} - -// String returns the string representation -func (s GetTransitGatewayRouteTableAssociationsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayRouteTableAssociationsOutput) GoString() string { - return s.String() -} - -// SetAssociations sets the Associations field's value. -func (s *GetTransitGatewayRouteTableAssociationsOutput) SetAssociations(v []*TransitGatewayRouteTableAssociation) *GetTransitGatewayRouteTableAssociationsOutput { - s.Associations = v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayRouteTableAssociationsOutput) SetNextToken(v string) *GetTransitGatewayRouteTableAssociationsOutput { - s.NextToken = &v - return s -} - -type GetTransitGatewayRouteTablePropagationsInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * resource-id - The ID of the resource. - // - // * resource-type - The resource type (vpc | vpn). - // - // * transit-gateway-attachment-id - The ID of the attachment. - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list"` - - // The maximum number of results to return with a single call. To retrieve the - // remaining results, make another call with the returned nextToken value. - MaxResults *int64 `min:"5" type:"integer"` - - // The token for the next page of results. - NextToken *string `type:"string"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s GetTransitGatewayRouteTablePropagationsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayRouteTablePropagationsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetTransitGatewayRouteTablePropagationsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetTransitGatewayRouteTablePropagationsInput"} - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *GetTransitGatewayRouteTablePropagationsInput) SetDryRun(v bool) *GetTransitGatewayRouteTablePropagationsInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *GetTransitGatewayRouteTablePropagationsInput) SetFilters(v []*Filter) *GetTransitGatewayRouteTablePropagationsInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *GetTransitGatewayRouteTablePropagationsInput) SetMaxResults(v int64) *GetTransitGatewayRouteTablePropagationsInput { - s.MaxResults = &v - return s -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayRouteTablePropagationsInput) SetNextToken(v string) *GetTransitGatewayRouteTablePropagationsInput { - s.NextToken = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *GetTransitGatewayRouteTablePropagationsInput) SetTransitGatewayRouteTableId(v string) *GetTransitGatewayRouteTablePropagationsInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type GetTransitGatewayRouteTablePropagationsOutput struct { - _ struct{} `type:"structure"` - - // The token to use to retrieve the next page of results. This value is null - // when there are no more results to return. - NextToken *string `locationName:"nextToken" type:"string"` - - // Information about the route table propagations. - TransitGatewayRouteTablePropagations []*TransitGatewayRouteTablePropagation `locationName:"transitGatewayRouteTablePropagations" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s GetTransitGatewayRouteTablePropagationsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s GetTransitGatewayRouteTablePropagationsOutput) GoString() string { - return s.String() -} - -// SetNextToken sets the NextToken field's value. -func (s *GetTransitGatewayRouteTablePropagationsOutput) SetNextToken(v string) *GetTransitGatewayRouteTablePropagationsOutput { - s.NextToken = &v - return s -} - -// SetTransitGatewayRouteTablePropagations sets the TransitGatewayRouteTablePropagations field's value. -func (s *GetTransitGatewayRouteTablePropagationsOutput) SetTransitGatewayRouteTablePropagations(v []*TransitGatewayRouteTablePropagation) *GetTransitGatewayRouteTablePropagationsOutput { - s.TransitGatewayRouteTablePropagations = v - return s -} - // Describes a security group. type GroupIdentifier struct { _ struct{} `type:"structure"` @@ -65332,71 +47613,14 @@ func (s *GroupIdentifier) SetGroupName(v string) *GroupIdentifier { return s } -// Indicates whether your instance is configured for hibernation. This parameter -// is valid only if the instance meets the hibernation prerequisites (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#hibernating-prerequisites). -// Hibernation is currently supported only for Amazon Linux. For more information, -// see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) -// in the Amazon Elastic Compute Cloud User Guide. -type HibernationOptions struct { - _ struct{} `type:"structure"` - - // If this parameter is set to true, your instance is enabled for hibernation; - // otherwise, it is not enabled for hibernation. - Configured *bool `locationName:"configured" type:"boolean"` -} - -// String returns the string representation -func (s HibernationOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s HibernationOptions) GoString() string { - return s.String() -} - -// SetConfigured sets the Configured field's value. -func (s *HibernationOptions) SetConfigured(v bool) *HibernationOptions { - s.Configured = &v - return s -} - -// Indicates whether your instance is configured for hibernation. This parameter -// is valid only if the instance meets the hibernation prerequisites (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#hibernating-prerequisites). -// Hibernation is currently supported only for Amazon Linux. For more information, -// see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) -// in the Amazon Elastic Compute Cloud User Guide. -type HibernationOptionsRequest struct { - _ struct{} `type:"structure"` - - // If you set this parameter to true, your instance is enabled for hibernation. - // - // Default: false - Configured *bool `type:"boolean"` -} - -// String returns the string representation -func (s HibernationOptionsRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s HibernationOptionsRequest) GoString() string { - return s.String() -} - -// SetConfigured sets the Configured field's value. -func (s *HibernationOptionsRequest) SetConfigured(v bool) *HibernationOptionsRequest { - s.Configured = &v - return s -} - // Describes an event in the history of the Spot Fleet request. type HistoryRecord struct { _ struct{} `type:"structure"` // Information about the event. - EventInformation *EventInformation `locationName:"eventInformation" type:"structure"` + // + // EventInformation is a required field + EventInformation *EventInformation `locationName:"eventInformation" type:"structure" required:"true"` // The event type. // @@ -65408,10 +47632,14 @@ type HistoryRecord struct { // * instanceChange - An instance was launched or terminated. // // * Information - An informational event. - EventType *string `locationName:"eventType" type:"string" enum:"EventType"` + // + // EventType is a required field + EventType *string `locationName:"eventType" type:"string" required:"true" enum:"EventType"` // The date and time of the event, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). - Timestamp *time.Time `locationName:"timestamp" type:"timestamp"` + // + // Timestamp is a required field + Timestamp *time.Time `locationName:"timestamp" type:"timestamp" required:"true"` } // String returns the string representation @@ -65500,8 +47728,9 @@ type Host struct { // The number of new instances that can be launched onto the Dedicated Host. AvailableCapacity *AvailableCapacity `locationName:"availableCapacity" type:"structure"` - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // Unique, case-sensitive identifier that you provide to ensure idempotency + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // in the Amazon Elastic Compute Cloud User Guide. ClientToken *string `locationName:"clientToken" type:"string"` // The ID of the Dedicated Host. @@ -65510,10 +47739,6 @@ type Host struct { // The hardware specifications of the Dedicated Host. HostProperties *HostProperties `locationName:"hostProperties" type:"structure"` - // Indicates whether host recovery is enabled or disabled for the Dedicated - // Host. - HostRecovery *string `locationName:"hostRecovery" type:"string" enum:"HostRecovery"` - // The reservation ID of the Dedicated Host. This returns a null response if // the Dedicated Host doesn't have an associated reservation. HostReservationId *string `locationName:"hostReservationId" type:"string"` @@ -65583,12 +47808,6 @@ func (s *Host) SetHostProperties(v *HostProperties) *Host { return s } -// SetHostRecovery sets the HostRecovery field's value. -func (s *Host) SetHostRecovery(v string) *Host { - s.HostRecovery = &v - return s -} - // SetHostReservationId sets the HostReservationId field's value. func (s *Host) SetHostReservationId(v string) *Host { s.HostReservationId = &v @@ -65826,9 +48045,6 @@ type HostReservation struct { // The state of the reservation. State *string `locationName:"state" type:"string" enum:"ReservationState"` - // Any tags assigned to the Dedicated Host Reservation. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - // The upfront price of the reservation. UpfrontPrice *string `locationName:"upfrontPrice" type:"string"` } @@ -65915,12 +48131,6 @@ func (s *HostReservation) SetState(v string) *HostReservation { return s } -// SetTags sets the Tags field's value. -func (s *HostReservation) SetTags(v []*Tag) *HostReservation { - s.Tags = v - return s -} - // SetUpfrontPrice sets the UpfrontPrice field's value. func (s *HostReservation) SetUpfrontPrice(v string) *HostReservation { s.UpfrontPrice = &v @@ -66175,7 +48385,7 @@ type Image struct { // The AWS account ID of the image owner. OwnerId *string `locationName:"imageOwnerId" type:"string"` - // This value is set for Windows AMIs; otherwise, it is blank. + // The value is Windows for Windows AMIs; otherwise blank. Platform *string `locationName:"platform" type:"string" enum:"PlatformValues"` // Any product codes associated with the AMI. @@ -66441,102 +48651,13 @@ func (s *ImageDiskContainer) SetUserBucket(v *UserBucket) *ImageDiskContainer { return s } -type ImportClientVpnClientCertificateRevocationListInput struct { - _ struct{} `type:"structure"` - - // The client certificate revocation list file. For more information, see Generate - // a Client Certificate Revocation List (https://docs.aws.amazon.com/vpn/latest/clientvpn-admin/cvpn-working-certificates.html#cvpn-working-certificates-generate) - // in the AWS Client VPN Administrator Guide. - // - // CertificateRevocationList is a required field - CertificateRevocationList *string `type:"string" required:"true"` - - // The ID of the Client VPN endpoint to which the client certificate revocation - // list applies. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s ImportClientVpnClientCertificateRevocationListInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ImportClientVpnClientCertificateRevocationListInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ImportClientVpnClientCertificateRevocationListInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ImportClientVpnClientCertificateRevocationListInput"} - if s.CertificateRevocationList == nil { - invalidParams.Add(request.NewErrParamRequired("CertificateRevocationList")) - } - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCertificateRevocationList sets the CertificateRevocationList field's value. -func (s *ImportClientVpnClientCertificateRevocationListInput) SetCertificateRevocationList(v string) *ImportClientVpnClientCertificateRevocationListInput { - s.CertificateRevocationList = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ImportClientVpnClientCertificateRevocationListInput) SetClientVpnEndpointId(v string) *ImportClientVpnClientCertificateRevocationListInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ImportClientVpnClientCertificateRevocationListInput) SetDryRun(v bool) *ImportClientVpnClientCertificateRevocationListInput { - s.DryRun = &v - return s -} - -type ImportClientVpnClientCertificateRevocationListOutput struct { - _ struct{} `type:"structure"` - - // Returns true if the request succeeds; otherwise, it returns an error. - Return *bool `locationName:"return" type:"boolean"` -} - -// String returns the string representation -func (s ImportClientVpnClientCertificateRevocationListOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ImportClientVpnClientCertificateRevocationListOutput) GoString() string { - return s.String() -} - -// SetReturn sets the Return field's value. -func (s *ImportClientVpnClientCertificateRevocationListOutput) SetReturn(v bool) *ImportClientVpnClientCertificateRevocationListOutput { - s.Return = &v - return s -} - +// Contains the parameters for ImportImage. type ImportImageInput struct { _ struct{} `type:"structure"` // The architecture of the virtual machine. // - // Valid values: i386 | x86_64 | arm64 + // Valid values: i386 | x86_64 Architecture *string `type:"string"` // The client-specific data. @@ -66557,58 +48678,19 @@ type ImportImageInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // Specifies whether the destination AMI of the imported image should be encrypted. - // The default CMK for EBS is used unless you specify a non-default AWS Key - // Management Service (AWS KMS) CMK using KmsKeyId. For more information, see - // Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) - // in the Amazon Elastic Compute Cloud User Guide. - Encrypted *bool `type:"boolean"` - // The target hypervisor platform. // // Valid values: xen Hypervisor *string `type:"string"` - // An identifier for the AWS Key Management Service (AWS KMS) customer master - // key (CMK) to use when creating the encrypted AMI. This parameter is only - // required if you want to use a non-default CMK; if this parameter is not specified, - // the default CMK for EBS is used. If a KmsKeyId is specified, the Encrypted - // flag must also be set. - // - // The CMK identifier may be provided in any of the following formats: - // - // * Key ID - // - // * Key alias. The alias ARN contains the arn:aws:kms namespace, followed - // by the Region of the CMK, the AWS account ID of the CMK owner, the alias - // namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. - // - // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed - // by the Region of the CMK, the AWS account ID of the CMK owner, the key - // namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. - // - // * ARN using key alias. The alias ARN contains the arn:aws:kms namespace, - // followed by the Region of the CMK, the AWS account ID of the CMK owner, - // the alias namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. - // - // AWS parses KmsKeyId asynchronously, meaning that the action you call may - // appear to complete even though you provided an invalid identifier. This action - // will eventually report failure. - // - // The specified CMK must exist in the Region that the AMI is being copied to. - KmsKeyId *string `type:"string"` - // The license type to be used for the Amazon Machine Image (AMI) after importing. // - // By default, we detect the source-system operating system (OS) and apply the - // appropriate license. Specify AWS to replace the source-system license with - // an AWS license, if appropriate. Specify BYOL to retain the source-system - // license, if appropriate. - // - // To use BYOL, you must have existing licenses with rights to use these licenses - // in a third party cloud, such as AWS. For more information, see Prerequisites - // (https://docs.aws.amazon.com/vm-import/latest/userguide/vmimport-image-import.html#prerequisites-image) + // Note: You may only use BYOL if you have existing licenses with rights to + // use these licenses in a third party cloud like AWS. For more information, + // see Prerequisites (http://docs.aws.amazon.com/vm-import/latest/userguide/vmimport-image-import.html#prerequisites-image) // in the VM Import/Export User Guide. + // + // Valid values: AWS | BYOL LicenseType *string `type:"string"` // The operating system of the virtual machine. @@ -66666,24 +48748,12 @@ func (s *ImportImageInput) SetDryRun(v bool) *ImportImageInput { return s } -// SetEncrypted sets the Encrypted field's value. -func (s *ImportImageInput) SetEncrypted(v bool) *ImportImageInput { - s.Encrypted = &v - return s -} - // SetHypervisor sets the Hypervisor field's value. func (s *ImportImageInput) SetHypervisor(v string) *ImportImageInput { s.Hypervisor = &v return s } -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ImportImageInput) SetKmsKeyId(v string) *ImportImageInput { - s.KmsKeyId = &v - return s -} - // SetLicenseType sets the LicenseType field's value. func (s *ImportImageInput) SetLicenseType(v string) *ImportImageInput { s.LicenseType = &v @@ -66702,6 +48772,7 @@ func (s *ImportImageInput) SetRoleName(v string) *ImportImageInput { return s } +// Contains the output for ImportImage. type ImportImageOutput struct { _ struct{} `type:"structure"` @@ -66711,9 +48782,6 @@ type ImportImageOutput struct { // A description of the import task. Description *string `locationName:"description" type:"string"` - // Indicates whether the AMI is encypted. - Encrypted *bool `locationName:"encrypted" type:"boolean"` - // The target hypervisor of the import task. Hypervisor *string `locationName:"hypervisor" type:"string"` @@ -66723,10 +48791,6 @@ type ImportImageOutput struct { // The task ID of the import image task. ImportTaskId *string `locationName:"importTaskId" type:"string"` - // The identifier for the AWS Key Management Service (AWS KMS) customer master - // key (CMK) that was used to create the encrypted AMI. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // The license type of the virtual machine. LicenseType *string `locationName:"licenseType" type:"string"` @@ -66768,12 +48832,6 @@ func (s *ImportImageOutput) SetDescription(v string) *ImportImageOutput { return s } -// SetEncrypted sets the Encrypted field's value. -func (s *ImportImageOutput) SetEncrypted(v bool) *ImportImageOutput { - s.Encrypted = &v - return s -} - // SetHypervisor sets the Hypervisor field's value. func (s *ImportImageOutput) SetHypervisor(v string) *ImportImageOutput { s.Hypervisor = &v @@ -66792,12 +48850,6 @@ func (s *ImportImageOutput) SetImportTaskId(v string) *ImportImageOutput { return s } -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ImportImageOutput) SetKmsKeyId(v string) *ImportImageOutput { - s.KmsKeyId = &v - return s -} - // SetLicenseType sets the LicenseType field's value. func (s *ImportImageOutput) SetLicenseType(v string) *ImportImageOutput { s.LicenseType = &v @@ -66840,15 +48892,12 @@ type ImportImageTask struct { // The architecture of the virtual machine. // - // Valid values: i386 | x86_64 | arm64 + // Valid values: i386 | x86_64 Architecture *string `locationName:"architecture" type:"string"` // A description of the import task. Description *string `locationName:"description" type:"string"` - // Indicates whether the image is encrypted. - Encrypted *bool `locationName:"encrypted" type:"boolean"` - // The target hypervisor for the import task. // // Valid values: xen @@ -66860,10 +48909,6 @@ type ImportImageTask struct { // The ID of the import image task. ImportTaskId *string `locationName:"importTaskId" type:"string"` - // The identifier for the AWS Key Management Service (AWS KMS) customer master - // key (CMK) that was used to create the encrypted image. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // The license type of the virtual machine. LicenseType *string `locationName:"licenseType" type:"string"` @@ -66905,12 +48950,6 @@ func (s *ImportImageTask) SetDescription(v string) *ImportImageTask { return s } -// SetEncrypted sets the Encrypted field's value. -func (s *ImportImageTask) SetEncrypted(v bool) *ImportImageTask { - s.Encrypted = &v - return s -} - // SetHypervisor sets the Hypervisor field's value. func (s *ImportImageTask) SetHypervisor(v string) *ImportImageTask { s.Hypervisor = &v @@ -66929,12 +48968,6 @@ func (s *ImportImageTask) SetImportTaskId(v string) *ImportImageTask { return s } -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ImportImageTask) SetKmsKeyId(v string) *ImportImageTask { - s.KmsKeyId = &v - return s -} - // SetLicenseType sets the LicenseType field's value. func (s *ImportImageTask) SetLicenseType(v string) *ImportImageTask { s.LicenseType = &v @@ -66971,6 +49004,7 @@ func (s *ImportImageTask) SetStatusMessage(v string) *ImportImageTask { return s } +// Contains the parameters for ImportInstance. type ImportInstanceInput struct { _ struct{} `type:"structure"` @@ -67068,10 +49102,10 @@ type ImportInstanceLaunchSpecification struct { // The architecture of the instance. Architecture *string `locationName:"architecture" type:"string" enum:"ArchitectureValues"` - // The security group IDs. + // One or more security group IDs. GroupIds []*string `locationName:"GroupId" locationNameList:"SecurityGroupId" type:"list"` - // The security group names. + // One or more security group names. GroupNames []*string `locationName:"GroupName" locationNameList:"SecurityGroup" type:"list"` // Indicates whether an instance stops or terminates when you initiate shutdown @@ -67079,7 +49113,7 @@ type ImportInstanceLaunchSpecification struct { InstanceInitiatedShutdownBehavior *string `locationName:"instanceInitiatedShutdownBehavior" type:"string" enum:"ShutdownBehavior"` // The instance type. For more information about the instance types that you - // can import, see Instance Types (https://docs.aws.amazon.com/vm-import/latest/userguide/vmie_prereqs.html#vmimport-instance-types) + // can import, see Instance Types (http://docs.aws.amazon.com/vm-import/latest/userguide/vmie_prereqs.html#vmimport-instance-types) // in the VM Import/Export User Guide. InstanceType *string `locationName:"instanceType" type:"string" enum:"InstanceType"` @@ -67175,6 +49209,7 @@ func (s *ImportInstanceLaunchSpecification) SetUserData(v *UserData) *ImportInst return s } +// Contains the output for ImportInstance. type ImportInstanceOutput struct { _ struct{} `type:"structure"` @@ -67211,7 +49246,7 @@ type ImportInstanceTaskDetails struct { // The instance operating system. Platform *string `locationName:"platform" type:"string" enum:"PlatformValues"` - // The volumes. + // One or more volumes. Volumes []*ImportInstanceVolumeDetailItem `locationName:"volumes" locationNameList:"item" type:"list"` } @@ -67254,25 +49289,35 @@ type ImportInstanceVolumeDetailItem struct { _ struct{} `type:"structure"` // The Availability Zone where the resulting instance will reside. - AvailabilityZone *string `locationName:"availabilityZone" type:"string"` + // + // AvailabilityZone is a required field + AvailabilityZone *string `locationName:"availabilityZone" type:"string" required:"true"` // The number of bytes converted so far. - BytesConverted *int64 `locationName:"bytesConverted" type:"long"` + // + // BytesConverted is a required field + BytesConverted *int64 `locationName:"bytesConverted" type:"long" required:"true"` // A description of the task. Description *string `locationName:"description" type:"string"` // The image. - Image *DiskImageDescription `locationName:"image" type:"structure"` + // + // Image is a required field + Image *DiskImageDescription `locationName:"image" type:"structure" required:"true"` // The status of the import of this particular disk image. - Status *string `locationName:"status" type:"string"` + // + // Status is a required field + Status *string `locationName:"status" type:"string" required:"true"` // The status information or errors related to the disk image. StatusMessage *string `locationName:"statusMessage" type:"string"` // The volume. - Volume *DiskImageVolumeDescription `locationName:"volume" type:"structure"` + // + // Volume is a required field + Volume *DiskImageVolumeDescription `locationName:"volume" type:"structure" required:"true"` } // String returns the string representation @@ -67327,6 +49372,7 @@ func (s *ImportInstanceVolumeDetailItem) SetVolume(v *DiskImageVolumeDescription return s } +// Contains the parameters for ImportKeyPair. type ImportKeyPairInput struct { _ struct{} `type:"structure"` @@ -67394,6 +49440,7 @@ func (s *ImportKeyPairInput) SetPublicKeyMaterial(v []byte) *ImportKeyPairInput return s } +// Contains the output of ImportKeyPair. type ImportKeyPairOutput struct { _ struct{} `type:"structure"` @@ -67426,6 +49473,7 @@ func (s *ImportKeyPairOutput) SetKeyName(v string) *ImportKeyPairOutput { return s } +// Contains the parameters for ImportSnapshot. type ImportSnapshotInput struct { _ struct{} `type:"structure"` @@ -67447,43 +49495,6 @@ type ImportSnapshotInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // Specifies whether the destination snapshot of the imported image should be - // encrypted. The default CMK for EBS is used unless you specify a non-default - // AWS Key Management Service (AWS KMS) CMK using KmsKeyId. For more information, - // see Amazon EBS Encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html) - // in the Amazon Elastic Compute Cloud User Guide. - Encrypted *bool `type:"boolean"` - - // An identifier for the AWS Key Management Service (AWS KMS) customer master - // key (CMK) to use when creating the encrypted snapshot. This parameter is - // only required if you want to use a non-default CMK; if this parameter is - // not specified, the default CMK for EBS is used. If a KmsKeyId is specified, - // the Encrypted flag must also be set. - // - // The CMK identifier may be provided in any of the following formats: - // - // * Key ID - // - // * Key alias. The alias ARN contains the arn:aws:kms namespace, followed - // by the Region of the CMK, the AWS account ID of the CMK owner, the alias - // namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. - // - // * ARN using key ID. The ID ARN contains the arn:aws:kms namespace, followed - // by the Region of the CMK, the AWS account ID of the CMK owner, the key - // namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. - // - // * ARN using key alias. The alias ARN contains the arn:aws:kms namespace, - // followed by the Region of the CMK, the AWS account ID of the CMK owner, - // the alias namespace, and then the CMK alias. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. - // - // AWS parses KmsKeyId asynchronously, meaning that the action you call may - // appear to complete even though you provided an invalid identifier. This action - // will eventually report failure. - // - // The specified CMK must exist in the Region that the snapshot is being copied - // to. - KmsKeyId *string `type:"string"` - // The name of the role to use when not using the default role, 'vmimport'. RoleName *string `type:"string"` } @@ -67528,24 +49539,13 @@ func (s *ImportSnapshotInput) SetDryRun(v bool) *ImportSnapshotInput { return s } -// SetEncrypted sets the Encrypted field's value. -func (s *ImportSnapshotInput) SetEncrypted(v bool) *ImportSnapshotInput { - s.Encrypted = &v - return s -} - -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ImportSnapshotInput) SetKmsKeyId(v string) *ImportSnapshotInput { - s.KmsKeyId = &v - return s -} - // SetRoleName sets the RoleName field's value. func (s *ImportSnapshotInput) SetRoleName(v string) *ImportSnapshotInput { s.RoleName = &v return s } +// Contains the output for ImportSnapshot. type ImportSnapshotOutput struct { _ struct{} `type:"structure"` @@ -67629,6 +49629,7 @@ func (s *ImportSnapshotTask) SetSnapshotTaskDetail(v *SnapshotTaskDetail) *Impor return s } +// Contains the parameters for ImportVolume. type ImportVolumeInput struct { _ struct{} `type:"structure"` @@ -67726,6 +49727,7 @@ func (s *ImportVolumeInput) SetVolume(v *VolumeDetail) *ImportVolumeInput { return s } +// Contains the output for ImportVolume. type ImportVolumeOutput struct { _ struct{} `type:"structure"` @@ -67823,12 +49825,6 @@ type Instance struct { // Any block device mapping entries for the instance. BlockDeviceMappings []*InstanceBlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"` - // The ID of the Capacity Reservation. - CapacityReservationId *string `locationName:"capacityReservationId" type:"string"` - - // Information about the Capacity Reservation targeting option. - CapacityReservationSpecification *CapacityReservationSpecificationResponse `locationName:"capacityReservationSpecification" type:"structure"` - // The idempotency token you provided when you launched the instance, if applicable. ClientToken *string `locationName:"clientToken" type:"string"` @@ -67845,15 +49841,9 @@ type Instance struct { // The Elastic GPU associated with the instance. ElasticGpuAssociations []*ElasticGpuAssociation `locationName:"elasticGpuAssociationSet" locationNameList:"item" type:"list"` - // The elastic inference accelerator associated with the instance. - ElasticInferenceAcceleratorAssociations []*ElasticInferenceAcceleratorAssociation `locationName:"elasticInferenceAcceleratorAssociationSet" locationNameList:"item" type:"list"` - // Specifies whether enhanced networking with ENA is enabled. EnaSupport *bool `locationName:"enaSupport" type:"boolean"` - // Indicates whether the instance is enabled for hibernation. - HibernationOptions *HibernationOptions `locationName:"hibernationOptions" type:"structure"` - // The hypervisor type of the instance. Hypervisor *string `locationName:"hypervisor" type:"string" enum:"HypervisorType"` @@ -67882,13 +49872,10 @@ type Instance struct { // The time the instance was launched. LaunchTime *time.Time `locationName:"launchTime" type:"timestamp"` - // The license configurations. - Licenses []*LicenseConfiguration `locationName:"licenseSet" locationNameList:"item" type:"list"` - // The monitoring for the instance. Monitoring *Monitoring `locationName:"monitoring" type:"structure"` - // [EC2-VPC] The network interfaces for the instance. + // [EC2-VPC] One or more network interfaces for the instance. NetworkInterfaces []*InstanceNetworkInterface `locationName:"networkInterfaceSet" locationNameList:"item" type:"list"` // The location where the instance launched, if applicable. @@ -67931,14 +49918,14 @@ type Instance struct { // instance store volume. RootDeviceType *string `locationName:"rootDeviceType" type:"string" enum:"DeviceType"` - // The security groups for the instance. + // One or more security groups for the instance. SecurityGroups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"` // Specifies whether to enable an instance launched in a VPC to perform NAT. // This controls whether source/destination checking is enabled on the instance. // A value of true means that checking is enabled, and false means that checking // is disabled. The value must be false for the instance to perform NAT. For - // more information, see NAT Instances (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) + // more information, see NAT Instances (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) // in the Amazon Virtual Private Cloud User Guide. SourceDestCheck *bool `locationName:"sourceDestCheck" type:"boolean"` @@ -67999,18 +49986,6 @@ func (s *Instance) SetBlockDeviceMappings(v []*InstanceBlockDeviceMapping) *Inst return s } -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *Instance) SetCapacityReservationId(v string) *Instance { - s.CapacityReservationId = &v - return s -} - -// SetCapacityReservationSpecification sets the CapacityReservationSpecification field's value. -func (s *Instance) SetCapacityReservationSpecification(v *CapacityReservationSpecificationResponse) *Instance { - s.CapacityReservationSpecification = v - return s -} - // SetClientToken sets the ClientToken field's value. func (s *Instance) SetClientToken(v string) *Instance { s.ClientToken = &v @@ -68035,24 +50010,12 @@ func (s *Instance) SetElasticGpuAssociations(v []*ElasticGpuAssociation) *Instan return s } -// SetElasticInferenceAcceleratorAssociations sets the ElasticInferenceAcceleratorAssociations field's value. -func (s *Instance) SetElasticInferenceAcceleratorAssociations(v []*ElasticInferenceAcceleratorAssociation) *Instance { - s.ElasticInferenceAcceleratorAssociations = v - return s -} - // SetEnaSupport sets the EnaSupport field's value. func (s *Instance) SetEnaSupport(v bool) *Instance { s.EnaSupport = &v return s } -// SetHibernationOptions sets the HibernationOptions field's value. -func (s *Instance) SetHibernationOptions(v *HibernationOptions) *Instance { - s.HibernationOptions = v - return s -} - // SetHypervisor sets the Hypervisor field's value. func (s *Instance) SetHypervisor(v string) *Instance { s.Hypervisor = &v @@ -68107,12 +50070,6 @@ func (s *Instance) SetLaunchTime(v time.Time) *Instance { return s } -// SetLicenses sets the Licenses field's value. -func (s *Instance) SetLicenses(v []*LicenseConfiguration) *Instance { - s.Licenses = v - return s -} - // SetMonitoring sets the Monitoring field's value. func (s *Instance) SetMonitoring(v *Monitoring) *Instance { s.Monitoring = v @@ -68412,7 +50369,7 @@ func (s *InstanceCount) SetState(v string) *InstanceCount { return s } -// Describes the credit option for CPU usage of a T2 or T3 instance. +// Describes the credit option for CPU usage of a T2 instance. type InstanceCreditSpecification struct { _ struct{} `type:"structure"` @@ -68446,7 +50403,7 @@ func (s *InstanceCreditSpecification) SetInstanceId(v string) *InstanceCreditSpe return s } -// Describes the credit option for CPU usage of a T2 or T3 instance. +// Describes the credit option for CPU usage of a T2 instance. type InstanceCreditSpecificationRequest struct { _ struct{} `type:"structure"` @@ -68644,11 +50601,6 @@ type InstanceNetworkInterface struct { // One or more security groups. Groups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"` - // Describes the type of network interface. - // - // Valid values: interface | efa - InterfaceType *string `locationName:"interfaceType" type:"string"` - // One or more IPv6 addresses associated with the network interface. Ipv6Addresses []*InstanceIpv6Address `locationName:"ipv6AddressesSet" locationNameList:"item" type:"list"` @@ -68717,12 +50669,6 @@ func (s *InstanceNetworkInterface) SetGroups(v []*GroupIdentifier) *InstanceNetw return s } -// SetInterfaceType sets the InterfaceType field's value. -func (s *InstanceNetworkInterface) SetInterfaceType(v string) *InstanceNetworkInterface { - s.InterfaceType = &v - return s -} - // SetIpv6Addresses sets the Ipv6Addresses field's value. func (s *InstanceNetworkInterface) SetIpv6Addresses(v []*InstanceIpv6Address) *InstanceNetworkInterface { s.Ipv6Addresses = v @@ -68911,26 +50857,15 @@ type InstanceNetworkInterfaceSpecification struct { // interface when launching an instance. Description *string `locationName:"description" type:"string"` - // The position of the network interface in the attachment order. A primary - // network interface has a device index of 0. - // - // If you specify a network interface when launching an instance, you must specify - // the device index. + // The index of the device on the instance for the network interface attachment. + // If you are specifying a network interface in a RunInstances request, you + // must provide the device index. DeviceIndex *int64 `locationName:"deviceIndex" type:"integer"` // The IDs of the security groups for the network interface. Applies only if // creating a network interface when launching an instance. Groups []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` - // The type of network interface. To create an Elastic Fabric Adapter (EFA), - // specify efa. For more information, see Elastic Fabric Adapter (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/efa.html) - // in the Amazon Elastic Compute Cloud User Guide. - // - // If you are not creating an EFA, specify interface or omit this parameter. - // - // Valid values: interface | efa - InterfaceType *string `type:"string"` - // A number of IPv6 addresses to assign to the network interface. Amazon EC2 // chooses the IPv6 addresses from the range of the subnet. You cannot specify // this option and the option to assign specific IPv6 addresses in the same @@ -68949,22 +50884,19 @@ type InstanceNetworkInterfaceSpecification struct { // The private IPv4 address of the network interface. Applies only if creating // a network interface when launching an instance. You cannot specify this option - // if you're launching more than one instance in a RunInstances (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) - // request. + // if you're launching more than one instance in a RunInstances request. PrivateIpAddress *string `locationName:"privateIpAddress" type:"string"` // One or more private IPv4 addresses to assign to the network interface. Only // one private IPv4 address can be designated as primary. You cannot specify // this option if you're launching more than one instance in a RunInstances - // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) // request. PrivateIpAddresses []*PrivateIpAddressSpecification `locationName:"privateIpAddressesSet" queryName:"PrivateIpAddresses" locationNameList:"item" type:"list"` // The number of secondary private IPv4 addresses. You can't specify this option // and specify more than one private IP address using the private IP addresses // option. You cannot specify this option if you're launching more than one - // instance in a RunInstances (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RunInstances.html) - // request. + // instance in a RunInstances request. SecondaryPrivateIpAddressCount *int64 `locationName:"secondaryPrivateIpAddressCount" type:"integer"` // The ID of the subnet associated with the network string. Applies only if @@ -69012,12 +50944,6 @@ func (s *InstanceNetworkInterfaceSpecification) SetGroups(v []*string) *Instance return s } -// SetInterfaceType sets the InterfaceType field's value. -func (s *InstanceNetworkInterfaceSpecification) SetInterfaceType(v string) *InstanceNetworkInterfaceSpecification { - s.InterfaceType = &v - return s -} - // SetIpv6AddressCount sets the Ipv6AddressCount field's value. func (s *InstanceNetworkInterfaceSpecification) SetIpv6AddressCount(v int64) *InstanceNetworkInterfaceSpecification { s.Ipv6AddressCount = &v @@ -69112,54 +51038,12 @@ func (s *InstancePrivateIpAddress) SetPrivateIpAddress(v string) *InstancePrivat return s } -// The instance details to specify which volumes should be snapshotted. -type InstanceSpecification struct { - _ struct{} `type:"structure"` - - // Excludes the root volume from being snapshotted. - ExcludeBootVolume *bool `type:"boolean"` - - // The instance to specify which volumes should be snapshotted. - InstanceId *string `type:"string"` -} - -// String returns the string representation -func (s InstanceSpecification) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s InstanceSpecification) GoString() string { - return s.String() -} - -// SetExcludeBootVolume sets the ExcludeBootVolume field's value. -func (s *InstanceSpecification) SetExcludeBootVolume(v bool) *InstanceSpecification { - s.ExcludeBootVolume = &v - return s -} - -// SetInstanceId sets the InstanceId field's value. -func (s *InstanceSpecification) SetInstanceId(v string) *InstanceSpecification { - s.InstanceId = &v - return s -} - // Describes the current state of an instance. type InstanceState struct { _ struct{} `type:"structure"` - // The state of the instance as a 16-bit unsigned integer. - // - // The high byte is all of the bits between 2^8 and (2^16)-1, which equals decimal - // values between 256 and 65,535. These numerical values are used for internal - // purposes and should be ignored. - // - // The low byte is all of the bits between 2^0 and (2^8)-1, which equals decimal - // values between 0 and 255. - // - // The valid values for instance-state-code will all be in the range of the - // low byte and they are: + // The low byte represents the state. The high byte is used for internal purposes + // and should be ignored. // // * 0 : pending // @@ -69172,9 +51056,6 @@ type InstanceState struct { // * 64 : stopping // // * 80 : stopped - // - // You can ignore the high byte value by zeroing out all of the bits above 2^8 - // or 256 in decimal. Code *int64 `locationName:"code" type:"integer"` // The current state of the instance. @@ -69375,17 +51256,11 @@ type InstanceStatusEvent struct { // following text: [Completed]. Description *string `locationName:"description" type:"string"` - // The ID of the event. - InstanceEventId *string `locationName:"instanceEventId" type:"string"` - // The latest scheduled end time for the event. NotAfter *time.Time `locationName:"notAfter" type:"timestamp"` // The earliest scheduled start time for the event. NotBefore *time.Time `locationName:"notBefore" type:"timestamp"` - - // The deadline for starting the event. - NotBeforeDeadline *time.Time `locationName:"notBeforeDeadline" type:"timestamp"` } // String returns the string representation @@ -69410,12 +51285,6 @@ func (s *InstanceStatusEvent) SetDescription(v string) *InstanceStatusEvent { return s } -// SetInstanceEventId sets the InstanceEventId field's value. -func (s *InstanceStatusEvent) SetInstanceEventId(v string) *InstanceStatusEvent { - s.InstanceEventId = &v - return s -} - // SetNotAfter sets the NotAfter field's value. func (s *InstanceStatusEvent) SetNotAfter(v time.Time) *InstanceStatusEvent { s.NotAfter = &v @@ -69428,12 +51297,6 @@ func (s *InstanceStatusEvent) SetNotBefore(v time.Time) *InstanceStatusEvent { return s } -// SetNotBeforeDeadline sets the NotBeforeDeadline field's value. -func (s *InstanceStatusEvent) SetNotBeforeDeadline(v time.Time) *InstanceStatusEvent { - s.NotBeforeDeadline = &v - return s -} - // Describes the status of an instance. type InstanceStatusSummary struct { _ struct{} `type:"structure"` @@ -69477,9 +51340,6 @@ type InternetGateway struct { // The ID of the internet gateway. InternetGatewayId *string `locationName:"internetGatewayId" type:"string"` - // The ID of the AWS account that owns the internet gateway. - OwnerId *string `locationName:"ownerId" type:"string"` - // Any tags assigned to the internet gateway. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` } @@ -69506,12 +51366,6 @@ func (s *InternetGateway) SetInternetGatewayId(v string) *InternetGateway { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *InternetGateway) SetOwnerId(v string) *InternetGateway { - s.OwnerId = &v - return s -} - // SetTags sets the Tags field's value. func (s *InternetGateway) SetTags(v []*Tag) *InternetGateway { s.Tags = v @@ -69562,34 +51416,35 @@ type IpPermission struct { // all ICMP/ICMPv6 types, you must specify all codes. FromPort *int64 `locationName:"fromPort" type:"integer"` - // The IP protocol name (tcp, udp, icmp, icmpv6) or number (see Protocol Numbers - // (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml)). + // The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml)). // - // [VPC only] Use -1 to specify all protocols. When authorizing security group - // rules, specifying -1 or a protocol number other than tcp, udp, icmp, or icmpv6 - // allows traffic on all ports, regardless of any port range you specify. For - // tcp, udp, and icmp, you must specify a port range. For icmpv6, the port range - // is optional; if you omit the port range, traffic for all types and codes - // is allowed. + // [EC2-VPC only] Use -1 to specify all protocols. When authorizing security + // group rules, specifying -1 or a protocol number other than tcp, udp, icmp, + // or 58 (ICMPv6) allows traffic on all ports, regardless of any port range + // you specify. For tcp, udp, and icmp, you must specify a port range. For 58 + // (ICMPv6), you can optionally specify a port range; if you don't, traffic + // for all types and codes is allowed when authorizing rules. IpProtocol *string `locationName:"ipProtocol" type:"string"` - // The IPv4 ranges. + // One or more IPv4 ranges. IpRanges []*IpRange `locationName:"ipRanges" locationNameList:"item" type:"list"` - // [VPC only] The IPv6 ranges. + // [EC2-VPC only] One or more IPv6 ranges. Ipv6Ranges []*Ipv6Range `locationName:"ipv6Ranges" locationNameList:"item" type:"list"` - // [VPC only] The prefix list IDs for an AWS service. With outbound rules, this - // is the AWS service to access through a VPC endpoint from instances associated - // with the security group. + // (EC2-VPC only; valid for AuthorizeSecurityGroupEgress, RevokeSecurityGroupEgress + // and DescribeSecurityGroups only) One or more prefix list IDs for an AWS service. + // In an AuthorizeSecurityGroupEgress request, this is the AWS service that + // you want to access through a VPC endpoint from instances associated with + // the security group. PrefixListIds []*PrefixListId `locationName:"prefixListIds" locationNameList:"item" type:"list"` // The end of port range for the TCP and UDP protocols, or an ICMP/ICMPv6 code. - // A value of -1 indicates all ICMP/ICMPv6 codes. If you specify all ICMP/ICMPv6 - // types, you must specify all codes. + // A value of -1 indicates all ICMP/ICMPv6 codes for the specified ICMP type. + // If you specify all ICMP/ICMPv6 types, you must specify all codes. ToPort *int64 `locationName:"toPort" type:"integer"` - // The security group and AWS account ID pairs. + // One or more security group and AWS account ID pairs. UserIdGroupPairs []*UserIdGroupPair `locationName:"groups" locationNameList:"item" type:"list"` } @@ -70085,40 +51940,6 @@ func (s *LaunchTemplate) SetTags(v []*Tag) *LaunchTemplate { return s } -// Describes a launch template and overrides. -type LaunchTemplateAndOverridesResponse struct { - _ struct{} `type:"structure"` - - // The launch template. - LaunchTemplateSpecification *FleetLaunchTemplateSpecification `locationName:"launchTemplateSpecification" type:"structure"` - - // Any parameters that you specify override the same parameters in the launch - // template. - Overrides *FleetLaunchTemplateOverrides `locationName:"overrides" type:"structure"` -} - -// String returns the string representation -func (s LaunchTemplateAndOverridesResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateAndOverridesResponse) GoString() string { - return s.String() -} - -// SetLaunchTemplateSpecification sets the LaunchTemplateSpecification field's value. -func (s *LaunchTemplateAndOverridesResponse) SetLaunchTemplateSpecification(v *FleetLaunchTemplateSpecification) *LaunchTemplateAndOverridesResponse { - s.LaunchTemplateSpecification = v - return s -} - -// SetOverrides sets the Overrides field's value. -func (s *LaunchTemplateAndOverridesResponse) SetOverrides(v *FleetLaunchTemplateOverrides) *LaunchTemplateAndOverridesResponse { - s.Overrides = v - return s -} - // Describes a block device mapping. type LaunchTemplateBlockDeviceMapping struct { _ struct{} `type:"structure"` @@ -70228,91 +52049,6 @@ func (s *LaunchTemplateBlockDeviceMappingRequest) SetVirtualName(v string) *Laun return s } -// Describes an instance's Capacity Reservation targeting option. You can specify -// only one option at a time. Use the CapacityReservationPreference parameter -// to configure the instance to run in On-Demand capacity or to run in any open -// Capacity Reservation that has matching attributes (instance type, platform, -// Availability Zone). Use the CapacityReservationTarget parameter to explicitly -// target a specific Capacity Reservation. -type LaunchTemplateCapacityReservationSpecificationRequest struct { - _ struct{} `type:"structure"` - - // Indicates the instance's Capacity Reservation preferences. Possible preferences - // include: - // - // * open - The instance can run in any open Capacity Reservation that has - // matching attributes (instance type, platform, Availability Zone). - // - // * none - The instance avoids running in a Capacity Reservation even if - // one is available. The instance runs in On-Demand capacity. - CapacityReservationPreference *string `type:"string" enum:"CapacityReservationPreference"` - - // Information about the target Capacity Reservation. - CapacityReservationTarget *CapacityReservationTarget `type:"structure"` -} - -// String returns the string representation -func (s LaunchTemplateCapacityReservationSpecificationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateCapacityReservationSpecificationRequest) GoString() string { - return s.String() -} - -// SetCapacityReservationPreference sets the CapacityReservationPreference field's value. -func (s *LaunchTemplateCapacityReservationSpecificationRequest) SetCapacityReservationPreference(v string) *LaunchTemplateCapacityReservationSpecificationRequest { - s.CapacityReservationPreference = &v - return s -} - -// SetCapacityReservationTarget sets the CapacityReservationTarget field's value. -func (s *LaunchTemplateCapacityReservationSpecificationRequest) SetCapacityReservationTarget(v *CapacityReservationTarget) *LaunchTemplateCapacityReservationSpecificationRequest { - s.CapacityReservationTarget = v - return s -} - -// Information about the Capacity Reservation targeting option. -type LaunchTemplateCapacityReservationSpecificationResponse struct { - _ struct{} `type:"structure"` - - // Indicates the instance's Capacity Reservation preferences. Possible preferences - // include: - // - // * open - The instance can run in any open Capacity Reservation that has - // matching attributes (instance type, platform, Availability Zone). - // - // * none - The instance avoids running in a Capacity Reservation even if - // one is available. The instance runs in On-Demand capacity. - CapacityReservationPreference *string `locationName:"capacityReservationPreference" type:"string" enum:"CapacityReservationPreference"` - - // Information about the target Capacity Reservation. - CapacityReservationTarget *CapacityReservationTargetResponse `locationName:"capacityReservationTarget" type:"structure"` -} - -// String returns the string representation -func (s LaunchTemplateCapacityReservationSpecificationResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateCapacityReservationSpecificationResponse) GoString() string { - return s.String() -} - -// SetCapacityReservationPreference sets the CapacityReservationPreference field's value. -func (s *LaunchTemplateCapacityReservationSpecificationResponse) SetCapacityReservationPreference(v string) *LaunchTemplateCapacityReservationSpecificationResponse { - s.CapacityReservationPreference = &v - return s -} - -// SetCapacityReservationTarget sets the CapacityReservationTarget field's value. -func (s *LaunchTemplateCapacityReservationSpecificationResponse) SetCapacityReservationTarget(v *CapacityReservationTargetResponse) *LaunchTemplateCapacityReservationSpecificationResponse { - s.CapacityReservationTarget = v - return s -} - // Describes a launch template and overrides. type LaunchTemplateConfig struct { _ struct{} `type:"structure"` @@ -70526,8 +52262,8 @@ type LaunchTemplateEbsBlockDeviceRequest struct { // volume. For gp2, this represents the baseline performance of the volume and // the rate at which the volume accumulates I/O credits for bursting. For more // information about General Purpose SSD baseline performance, I/O credits, - // and bursting, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) - // in the Amazon Elastic Compute Cloud User Guide. + // and bursting, see Amazon EBS Volume Types in the Amazon Elastic Compute Cloud + // User Guide. // // Condition: This parameter is required for requests to create io1 volumes; // it is not used in requests to create gp2, st1, sc1, or standard volumes. @@ -70601,124 +52337,6 @@ func (s *LaunchTemplateEbsBlockDeviceRequest) SetVolumeType(v string) *LaunchTem return s } -// Describes an elastic inference accelerator. -type LaunchTemplateElasticInferenceAccelerator struct { - _ struct{} `type:"structure"` - - // The type of elastic inference accelerator. The possible values are eia1.medium, - // eia1.large, and eia1.xlarge. - // - // Type is a required field - Type *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s LaunchTemplateElasticInferenceAccelerator) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateElasticInferenceAccelerator) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *LaunchTemplateElasticInferenceAccelerator) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "LaunchTemplateElasticInferenceAccelerator"} - if s.Type == nil { - invalidParams.Add(request.NewErrParamRequired("Type")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetType sets the Type field's value. -func (s *LaunchTemplateElasticInferenceAccelerator) SetType(v string) *LaunchTemplateElasticInferenceAccelerator { - s.Type = &v - return s -} - -// Describes an elastic inference accelerator. -type LaunchTemplateElasticInferenceAcceleratorResponse struct { - _ struct{} `type:"structure"` - - // The type of elastic inference accelerator. The possible values are eia1.medium, - // eia1.large, and eia1.xlarge. - Type *string `locationName:"type" type:"string"` -} - -// String returns the string representation -func (s LaunchTemplateElasticInferenceAcceleratorResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateElasticInferenceAcceleratorResponse) GoString() string { - return s.String() -} - -// SetType sets the Type field's value. -func (s *LaunchTemplateElasticInferenceAcceleratorResponse) SetType(v string) *LaunchTemplateElasticInferenceAcceleratorResponse { - s.Type = &v - return s -} - -// Indicates whether an instance is configured for hibernation. -type LaunchTemplateHibernationOptions struct { - _ struct{} `type:"structure"` - - // If this parameter is set to true, the instance is enabled for hibernation; - // otherwise, it is not enabled for hibernation. - Configured *bool `locationName:"configured" type:"boolean"` -} - -// String returns the string representation -func (s LaunchTemplateHibernationOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateHibernationOptions) GoString() string { - return s.String() -} - -// SetConfigured sets the Configured field's value. -func (s *LaunchTemplateHibernationOptions) SetConfigured(v bool) *LaunchTemplateHibernationOptions { - s.Configured = &v - return s -} - -// Indicates whether the instance is configured for hibernation. This parameter -// is valid only if the instance meets the hibernation prerequisites (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#hibernating-prerequisites). -// Hibernation is currently supported only for Amazon Linux. -type LaunchTemplateHibernationOptionsRequest struct { - _ struct{} `type:"structure"` - - // If you set this parameter to true, the instance is enabled for hibernation. - // - // Default: false - Configured *bool `type:"boolean"` -} - -// String returns the string representation -func (s LaunchTemplateHibernationOptionsRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateHibernationOptionsRequest) GoString() string { - return s.String() -} - -// SetConfigured sets the Configured field's value. -func (s *LaunchTemplateHibernationOptionsRequest) SetConfigured(v bool) *LaunchTemplateHibernationOptionsRequest { - s.Configured = &v - return s -} - // Describes an IAM instance profile. type LaunchTemplateIamInstanceProfileSpecification struct { _ struct{} `type:"structure"` @@ -70871,9 +52489,6 @@ type LaunchTemplateInstanceNetworkInterfaceSpecification struct { // The IDs of one or more security groups. Groups []*string `locationName:"groupSet" locationNameList:"groupId" type:"list"` - // The type of network interface. - InterfaceType *string `locationName:"interfaceType" type:"string"` - // The number of IPv6 addresses for the network interface. Ipv6AddressCount *int64 `locationName:"ipv6AddressCount" type:"integer"` @@ -70936,12 +52551,6 @@ func (s *LaunchTemplateInstanceNetworkInterfaceSpecification) SetGroups(v []*str return s } -// SetInterfaceType sets the InterfaceType field's value. -func (s *LaunchTemplateInstanceNetworkInterfaceSpecification) SetInterfaceType(v string) *LaunchTemplateInstanceNetworkInterfaceSpecification { - s.InterfaceType = &v - return s -} - // SetIpv6AddressCount sets the Ipv6AddressCount field's value. func (s *LaunchTemplateInstanceNetworkInterfaceSpecification) SetIpv6AddressCount(v int64) *LaunchTemplateInstanceNetworkInterfaceSpecification { s.Ipv6AddressCount = &v @@ -71003,15 +52612,6 @@ type LaunchTemplateInstanceNetworkInterfaceSpecificationRequest struct { // The IDs of one or more security groups. Groups []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` - // The type of network interface. To create an Elastic Fabric Adapter (EFA), - // specify efa. For more information, see Elastic Fabric Adapter (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/efa.html) - // in the Amazon Elastic Compute Cloud User Guide. - // - // If you are not creating an EFA, specify interface or omit this parameter. - // - // Valid values: interface | efa - InterfaceType *string `type:"string"` - // The number of IPv6 addresses to assign to a network interface. Amazon EC2 // automatically selects the IPv6 addresses from the subnet range. You can't // use this option if specifying specific IPv6 addresses. @@ -71077,12 +52677,6 @@ func (s *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest) SetGroups(v return s } -// SetInterfaceType sets the InterfaceType field's value. -func (s *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest) SetInterfaceType(v string) *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest { - s.InterfaceType = &v - return s -} - // SetIpv6AddressCount sets the Ipv6AddressCount field's value. func (s *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest) SetIpv6AddressCount(v int64) *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest { s.Ipv6AddressCount = &v @@ -71125,54 +52719,6 @@ func (s *LaunchTemplateInstanceNetworkInterfaceSpecificationRequest) SetSubnetId return s } -// Describes a license configuration. -type LaunchTemplateLicenseConfiguration struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the license configuration. - LicenseConfigurationArn *string `locationName:"licenseConfigurationArn" type:"string"` -} - -// String returns the string representation -func (s LaunchTemplateLicenseConfiguration) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateLicenseConfiguration) GoString() string { - return s.String() -} - -// SetLicenseConfigurationArn sets the LicenseConfigurationArn field's value. -func (s *LaunchTemplateLicenseConfiguration) SetLicenseConfigurationArn(v string) *LaunchTemplateLicenseConfiguration { - s.LicenseConfigurationArn = &v - return s -} - -// Describes a license configuration. -type LaunchTemplateLicenseConfigurationRequest struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the license configuration. - LicenseConfigurationArn *string `type:"string"` -} - -// String returns the string representation -func (s LaunchTemplateLicenseConfigurationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LaunchTemplateLicenseConfigurationRequest) GoString() string { - return s.String() -} - -// SetLicenseConfigurationArn sets the LicenseConfigurationArn field's value. -func (s *LaunchTemplateLicenseConfigurationRequest) SetLicenseConfigurationArn(v string) *LaunchTemplateLicenseConfigurationRequest { - s.LicenseConfigurationArn = &v - return s -} - // Describes overrides for a launch template. type LaunchTemplateOverrides struct { _ struct{} `type:"structure"` @@ -71317,7 +52863,7 @@ func (s *LaunchTemplatePlacement) SetTenancy(v string) *LaunchTemplatePlacement return s } -// Describes the placement of an instance. +// The placement for the instance. type LaunchTemplatePlacementRequest struct { _ struct{} `type:"structure"` @@ -71602,7 +53148,7 @@ type LaunchTemplateTagSpecificationRequest struct { // The type of resource to tag. Currently, the resource types that support tagging // on creation are instance and volume. To tag a resource after it has been - // created, see CreateTags (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html). + // created, see CreateTags. ResourceType *string `type:"string" enum:"ResourceType"` // The tags to apply to the resource. @@ -71768,54 +53314,6 @@ func (s *LaunchTemplatesMonitoringRequest) SetEnabled(v bool) *LaunchTemplatesMo return s } -// Describes a license configuration. -type LicenseConfiguration struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the license configuration. - LicenseConfigurationArn *string `locationName:"licenseConfigurationArn" type:"string"` -} - -// String returns the string representation -func (s LicenseConfiguration) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LicenseConfiguration) GoString() string { - return s.String() -} - -// SetLicenseConfigurationArn sets the LicenseConfigurationArn field's value. -func (s *LicenseConfiguration) SetLicenseConfigurationArn(v string) *LicenseConfiguration { - s.LicenseConfigurationArn = &v - return s -} - -// Describes a license configuration. -type LicenseConfigurationRequest struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the license configuration. - LicenseConfigurationArn *string `type:"string"` -} - -// String returns the string representation -func (s LicenseConfigurationRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s LicenseConfigurationRequest) GoString() string { - return s.String() -} - -// SetLicenseConfigurationArn sets the LicenseConfigurationArn field's value. -func (s *LicenseConfigurationRequest) SetLicenseConfigurationArn(v string) *LicenseConfigurationRequest { - s.LicenseConfigurationArn = &v - return s -} - // Describes the Classic Load Balancers and target groups to attach to a Spot // Fleet request. type LoadBalancersConfig struct { @@ -71969,335 +53467,6 @@ func (s *LoadPermissionRequest) SetUserId(v string) *LoadPermissionRequest { return s } -type ModifyCapacityReservationInput struct { - _ struct{} `type:"structure"` - - // The ID of the Capacity Reservation. - // - // CapacityReservationId is a required field - CapacityReservationId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The date and time at which the Capacity Reservation expires. When a Capacity - // Reservation expires, the reserved capacity is released and you can no longer - // launch instances into it. The Capacity Reservation's state changes to expired - // when it reaches its end date and time. - // - // The Capacity Reservation is cancelled within an hour from the specified time. - // For example, if you specify 5/31/2019, 13:30:55, the Capacity Reservation - // is guaranteed to end between 13:30:55 and 14:30:55 on 5/31/2019. - // - // You must provide an EndDate value if EndDateType is limited. Omit EndDate - // if EndDateType is unlimited. - EndDate *time.Time `type:"timestamp"` - - // Indicates the way in which the Capacity Reservation ends. A Capacity Reservation - // can have one of the following end types: - // - // * unlimited - The Capacity Reservation remains active until you explicitly - // cancel it. Do not provide an EndDate value if EndDateType is unlimited. - // - // * limited - The Capacity Reservation expires automatically at a specified - // date and time. You must provide an EndDate value if EndDateType is limited. - EndDateType *string `type:"string" enum:"EndDateType"` - - // The number of instances for which to reserve capacity. - InstanceCount *int64 `type:"integer"` -} - -// String returns the string representation -func (s ModifyCapacityReservationInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyCapacityReservationInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyCapacityReservationInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyCapacityReservationInput"} - if s.CapacityReservationId == nil { - invalidParams.Add(request.NewErrParamRequired("CapacityReservationId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCapacityReservationId sets the CapacityReservationId field's value. -func (s *ModifyCapacityReservationInput) SetCapacityReservationId(v string) *ModifyCapacityReservationInput { - s.CapacityReservationId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyCapacityReservationInput) SetDryRun(v bool) *ModifyCapacityReservationInput { - s.DryRun = &v - return s -} - -// SetEndDate sets the EndDate field's value. -func (s *ModifyCapacityReservationInput) SetEndDate(v time.Time) *ModifyCapacityReservationInput { - s.EndDate = &v - return s -} - -// SetEndDateType sets the EndDateType field's value. -func (s *ModifyCapacityReservationInput) SetEndDateType(v string) *ModifyCapacityReservationInput { - s.EndDateType = &v - return s -} - -// SetInstanceCount sets the InstanceCount field's value. -func (s *ModifyCapacityReservationInput) SetInstanceCount(v int64) *ModifyCapacityReservationInput { - s.InstanceCount = &v - return s -} - -type ModifyCapacityReservationOutput struct { - _ struct{} `type:"structure"` - - // Information about the Capacity Reservation. - Return *bool `locationName:"return" type:"boolean"` -} - -// String returns the string representation -func (s ModifyCapacityReservationOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyCapacityReservationOutput) GoString() string { - return s.String() -} - -// SetReturn sets the Return field's value. -func (s *ModifyCapacityReservationOutput) SetReturn(v bool) *ModifyCapacityReservationOutput { - s.Return = &v - return s -} - -type ModifyClientVpnEndpointInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint to modify. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Information about the client connection logging options. - // - // If you enable client connection logging, data about client connections is - // sent to a Cloudwatch Logs log stream. The following information is logged: - // - // * Client connection requests - // - // * Client connection results (successful and unsuccessful) - // - // * Reasons for unsuccessful client connection requests - // - // * Client connection termination time - ConnectionLogOptions *ConnectionLogOptions `type:"structure"` - - // A brief description of the Client VPN endpoint. - Description *string `type:"string"` - - // Information about the DNS servers to be used by Client VPN connections. A - // Client VPN endpoint can have up to two DNS servers. - DnsServers *DnsServersOptionsModifyStructure `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ARN of the server certificate to be used. The server certificate must - // be provisioned in AWS Certificate Manager (ACM). - ServerCertificateArn *string `type:"string"` -} - -// String returns the string representation -func (s ModifyClientVpnEndpointInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyClientVpnEndpointInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyClientVpnEndpointInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyClientVpnEndpointInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *ModifyClientVpnEndpointInput) SetClientVpnEndpointId(v string) *ModifyClientVpnEndpointInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetConnectionLogOptions sets the ConnectionLogOptions field's value. -func (s *ModifyClientVpnEndpointInput) SetConnectionLogOptions(v *ConnectionLogOptions) *ModifyClientVpnEndpointInput { - s.ConnectionLogOptions = v - return s -} - -// SetDescription sets the Description field's value. -func (s *ModifyClientVpnEndpointInput) SetDescription(v string) *ModifyClientVpnEndpointInput { - s.Description = &v - return s -} - -// SetDnsServers sets the DnsServers field's value. -func (s *ModifyClientVpnEndpointInput) SetDnsServers(v *DnsServersOptionsModifyStructure) *ModifyClientVpnEndpointInput { - s.DnsServers = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyClientVpnEndpointInput) SetDryRun(v bool) *ModifyClientVpnEndpointInput { - s.DryRun = &v - return s -} - -// SetServerCertificateArn sets the ServerCertificateArn field's value. -func (s *ModifyClientVpnEndpointInput) SetServerCertificateArn(v string) *ModifyClientVpnEndpointInput { - s.ServerCertificateArn = &v - return s -} - -type ModifyClientVpnEndpointOutput struct { - _ struct{} `type:"structure"` - - // Returns true if the request succeeds; otherwise, it returns an error. - Return *bool `locationName:"return" type:"boolean"` -} - -// String returns the string representation -func (s ModifyClientVpnEndpointOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyClientVpnEndpointOutput) GoString() string { - return s.String() -} - -// SetReturn sets the Return field's value. -func (s *ModifyClientVpnEndpointOutput) SetReturn(v bool) *ModifyClientVpnEndpointOutput { - s.Return = &v - return s -} - -type ModifyEbsDefaultKmsKeyIdInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The identifier of the AWS Key Management Service (AWS KMS) customer master - // key (CMK) to use for Amazon EBS encryption. If this parameter is not specified, - // your AWS managed CMK for EBS is used. If KmsKeyId is specified, the encrypted - // state must be true. - // - // You can specify the CMK using any of the following: - // - // * Key ID. For example, key/1234abcd-12ab-34cd-56ef-1234567890ab. - // - // * Key alias. For example, alias/ExampleAlias. - // - // * Key ARN. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. - // - // * Alias ARN. For example, arn:aws:kms:us-east-1:012345678910:alias/ExampleAlias. - // - // AWS authenticates the CMK asynchronously. Therefore, if you specify an ID, - // alias, or ARN that is not valid, the action can appear to complete, but eventually - // fails. - // - // KmsKeyId is a required field - KmsKeyId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ModifyEbsDefaultKmsKeyIdInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyEbsDefaultKmsKeyIdInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyEbsDefaultKmsKeyIdInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyEbsDefaultKmsKeyIdInput"} - if s.KmsKeyId == nil { - invalidParams.Add(request.NewErrParamRequired("KmsKeyId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyEbsDefaultKmsKeyIdInput) SetDryRun(v bool) *ModifyEbsDefaultKmsKeyIdInput { - s.DryRun = &v - return s -} - -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ModifyEbsDefaultKmsKeyIdInput) SetKmsKeyId(v string) *ModifyEbsDefaultKmsKeyIdInput { - s.KmsKeyId = &v - return s -} - -type ModifyEbsDefaultKmsKeyIdOutput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the default CMK for encryption by default. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` -} - -// String returns the string representation -func (s ModifyEbsDefaultKmsKeyIdOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyEbsDefaultKmsKeyIdOutput) GoString() string { - return s.String() -} - -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ModifyEbsDefaultKmsKeyIdOutput) SetKmsKeyId(v string) *ModifyEbsDefaultKmsKeyIdOutput { - s.KmsKeyId = &v - return s -} - type ModifyFleetInput struct { _ struct{} `type:"structure"` @@ -72430,16 +53599,17 @@ type ModifyFpgaImageAttributeInput struct { // The operation type. OperationType *string `type:"string" enum:"OperationType"` - // The product codes. After you add a product code to an AFI, it can't be removed. - // This parameter is valid only when modifying the productCodes attribute. + // One or more product codes. After you add a product code to an AFI, it can't + // be removed. This parameter is valid only when modifying the productCodes + // attribute. ProductCodes []*string `locationName:"ProductCode" locationNameList:"ProductCode" type:"list"` - // The user groups. This parameter is valid only when modifying the loadPermission - // attribute. + // One or more user groups. This parameter is valid only when modifying the + // loadPermission attribute. UserGroups []*string `locationName:"UserGroup" locationNameList:"UserGroup" type:"list"` - // The AWS account IDs. This parameter is valid only when modifying the loadPermission - // attribute. + // One or more AWS account IDs. This parameter is valid only when modifying + // the loadPermission attribute. UserIds []*string `locationName:"UserId" locationNameList:"UserId" type:"list"` } @@ -72549,21 +53719,19 @@ func (s *ModifyFpgaImageAttributeOutput) SetFpgaImageAttribute(v *FpgaImageAttri return s } +// Contains the parameters for ModifyHosts. type ModifyHostsInput struct { _ struct{} `type:"structure"` // Specify whether to enable or disable auto-placement. - AutoPlacement *string `locationName:"autoPlacement" type:"string" enum:"AutoPlacement"` + // + // AutoPlacement is a required field + AutoPlacement *string `locationName:"autoPlacement" type:"string" required:"true" enum:"AutoPlacement"` // The IDs of the Dedicated Hosts to modify. // // HostIds is a required field HostIds []*string `locationName:"hostId" locationNameList:"item" type:"list" required:"true"` - - // Indicates whether to enable or disable host recovery for the Dedicated Host. - // For more information, see Host Recovery (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/dedicated-hosts-recovery.html) - // in the Amazon Elastic Compute Cloud User Guide. - HostRecovery *string `type:"string" enum:"HostRecovery"` } // String returns the string representation @@ -72579,6 +53747,9 @@ func (s ModifyHostsInput) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *ModifyHostsInput) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ModifyHostsInput"} + if s.AutoPlacement == nil { + invalidParams.Add(request.NewErrParamRequired("AutoPlacement")) + } if s.HostIds == nil { invalidParams.Add(request.NewErrParamRequired("HostIds")) } @@ -72601,12 +53772,7 @@ func (s *ModifyHostsInput) SetHostIds(v []*string) *ModifyHostsInput { return s } -// SetHostRecovery sets the HostRecovery field's value. -func (s *ModifyHostsInput) SetHostRecovery(v string) *ModifyHostsInput { - s.HostRecovery = &v - return s -} - +// Contains the output of ModifyHosts. type ModifyHostsOutput struct { _ struct{} `type:"structure"` @@ -72640,6 +53806,7 @@ func (s *ModifyHostsOutput) SetUnsuccessful(v []*UnsuccessfulItem) *ModifyHostsO return s } +// Contains the parameters of ModifyIdFormat. type ModifyIdFormatInput struct { _ struct{} `type:"structure"` @@ -72715,6 +53882,7 @@ func (s ModifyIdFormatOutput) GoString() string { return s.String() } +// Contains the parameters of ModifyIdentityIdFormat. type ModifyIdentityIdFormatInput struct { _ struct{} `type:"structure"` @@ -72835,16 +54003,16 @@ type ModifyImageAttributeInput struct { // is launchPermission. OperationType *string `type:"string" enum:"OperationType"` - // The DevPay product codes. After you add a product code to an AMI, it can't - // be removed. + // One or more DevPay product codes. After you add a product code to an AMI, + // it can't be removed. ProductCodes []*string `locationName:"ProductCode" locationNameList:"ProductCode" type:"list"` - // The user groups. This parameter can be used only when the Attribute parameter - // is launchPermission. + // One or more user groups. This parameter can be used only when the Attribute + // parameter is launchPermission. UserGroups []*string `locationName:"UserGroup" locationNameList:"UserGroup" type:"list"` - // The AWS account IDs. This parameter can be used only when the Attribute parameter - // is launchPermission. + // One or more AWS account IDs. This parameter can be used only when the Attribute + // parameter is launchPermission. UserIds []*string `locationName:"UserId" locationNameList:"UserId" type:"list"` // The value of the attribute being modified. This parameter can be used only @@ -72949,6 +54117,7 @@ func (s ModifyImageAttributeOutput) GoString() string { return s.String() } +// Contains the parameters for ModifyInstanceAttribute. type ModifyInstanceAttributeInput struct { _ struct{} `type:"structure"` @@ -72962,7 +54131,7 @@ type ModifyInstanceAttributeInput struct { // // To add instance store volumes to an Amazon EBS-backed instance, you must // add them when you launch the instance. For more information, see Updating - // the Block Device Mapping when Launching an Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/block-device-mapping-concepts.html#Using_OverridingAMIBDM) + // the Block Device Mapping when Launching an Instance (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/block-device-mapping-concepts.html#Using_OverridingAMIBDM) // in the Amazon Elastic Compute Cloud User Guide. BlockDeviceMappings []*InstanceBlockDeviceMappingSpecification `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"` @@ -73005,18 +54174,18 @@ type ModifyInstanceAttributeInput struct { InstanceInitiatedShutdownBehavior *AttributeValue `locationName:"instanceInitiatedShutdownBehavior" type:"structure"` // Changes the instance type to the specified value. For more information, see - // Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html). + // Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html). // If the instance type is not valid, the error returned is InvalidInstanceAttributeValue. InstanceType *AttributeValue `locationName:"instanceType" type:"structure"` // Changes the instance's kernel to the specified value. We recommend that you // use PV-GRUB instead of kernels and RAM disks. For more information, see PV-GRUB - // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedKernels.html). + // (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedKernels.html). Kernel *AttributeValue `locationName:"kernel" type:"structure"` // Changes the instance's RAM disk to the specified value. We recommend that // you use PV-GRUB instead of kernels and RAM disks. For more information, see - // PV-GRUB (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedKernels.html). + // PV-GRUB (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedKernels.html). Ramdisk *AttributeValue `locationName:"ramdisk" type:"structure"` // Specifies whether source/destination checking is enabled. A value of true @@ -73178,99 +54347,12 @@ func (s ModifyInstanceAttributeOutput) GoString() string { return s.String() } -type ModifyInstanceCapacityReservationAttributesInput struct { - _ struct{} `type:"structure"` - - // Information about the Capacity Reservation targeting option. - // - // CapacityReservationSpecification is a required field - CapacityReservationSpecification *CapacityReservationSpecification `type:"structure" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the instance to be modified. - // - // InstanceId is a required field - InstanceId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ModifyInstanceCapacityReservationAttributesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyInstanceCapacityReservationAttributesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyInstanceCapacityReservationAttributesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyInstanceCapacityReservationAttributesInput"} - if s.CapacityReservationSpecification == nil { - invalidParams.Add(request.NewErrParamRequired("CapacityReservationSpecification")) - } - if s.InstanceId == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCapacityReservationSpecification sets the CapacityReservationSpecification field's value. -func (s *ModifyInstanceCapacityReservationAttributesInput) SetCapacityReservationSpecification(v *CapacityReservationSpecification) *ModifyInstanceCapacityReservationAttributesInput { - s.CapacityReservationSpecification = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyInstanceCapacityReservationAttributesInput) SetDryRun(v bool) *ModifyInstanceCapacityReservationAttributesInput { - s.DryRun = &v - return s -} - -// SetInstanceId sets the InstanceId field's value. -func (s *ModifyInstanceCapacityReservationAttributesInput) SetInstanceId(v string) *ModifyInstanceCapacityReservationAttributesInput { - s.InstanceId = &v - return s -} - -type ModifyInstanceCapacityReservationAttributesOutput struct { - _ struct{} `type:"structure"` - - // Returns true if the request succeeds; otherwise, it returns an error. - Return *bool `locationName:"return" type:"boolean"` -} - -// String returns the string representation -func (s ModifyInstanceCapacityReservationAttributesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyInstanceCapacityReservationAttributesOutput) GoString() string { - return s.String() -} - -// SetReturn sets the Return field's value. -func (s *ModifyInstanceCapacityReservationAttributesOutput) SetReturn(v bool) *ModifyInstanceCapacityReservationAttributesOutput { - s.Return = &v - return s -} - type ModifyInstanceCreditSpecificationInput struct { _ struct{} `type:"structure"` // A unique, case-sensitive token that you provide to ensure idempotency of // your modification request. For more information, see Ensuring Idempotency - // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // Checks whether you have the required permissions for the action, without @@ -73360,107 +54442,7 @@ func (s *ModifyInstanceCreditSpecificationOutput) SetUnsuccessfulInstanceCreditS return s } -type ModifyInstanceEventStartTimeInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the event whose date and time you are modifying. - // - // InstanceEventId is a required field - InstanceEventId *string `type:"string" required:"true"` - - // The ID of the instance with the scheduled event. - // - // InstanceId is a required field - InstanceId *string `type:"string" required:"true"` - - // The new date and time when the event will take place. - // - // NotBefore is a required field - NotBefore *time.Time `type:"timestamp" required:"true"` -} - -// String returns the string representation -func (s ModifyInstanceEventStartTimeInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyInstanceEventStartTimeInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyInstanceEventStartTimeInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyInstanceEventStartTimeInput"} - if s.InstanceEventId == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceEventId")) - } - if s.InstanceId == nil { - invalidParams.Add(request.NewErrParamRequired("InstanceId")) - } - if s.NotBefore == nil { - invalidParams.Add(request.NewErrParamRequired("NotBefore")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyInstanceEventStartTimeInput) SetDryRun(v bool) *ModifyInstanceEventStartTimeInput { - s.DryRun = &v - return s -} - -// SetInstanceEventId sets the InstanceEventId field's value. -func (s *ModifyInstanceEventStartTimeInput) SetInstanceEventId(v string) *ModifyInstanceEventStartTimeInput { - s.InstanceEventId = &v - return s -} - -// SetInstanceId sets the InstanceId field's value. -func (s *ModifyInstanceEventStartTimeInput) SetInstanceId(v string) *ModifyInstanceEventStartTimeInput { - s.InstanceId = &v - return s -} - -// SetNotBefore sets the NotBefore field's value. -func (s *ModifyInstanceEventStartTimeInput) SetNotBefore(v time.Time) *ModifyInstanceEventStartTimeInput { - s.NotBefore = &v - return s -} - -type ModifyInstanceEventStartTimeOutput struct { - _ struct{} `type:"structure"` - - // Describes a scheduled event for an instance. - Event *InstanceStatusEvent `locationName:"event" type:"structure"` -} - -// String returns the string representation -func (s ModifyInstanceEventStartTimeOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyInstanceEventStartTimeOutput) GoString() string { - return s.String() -} - -// SetEvent sets the Event field's value. -func (s *ModifyInstanceEventStartTimeOutput) SetEvent(v *InstanceStatusEvent) *ModifyInstanceEventStartTimeOutput { - s.Event = v - return s -} - +// Contains the parameters for ModifyInstancePlacement. type ModifyInstancePlacementInput struct { _ struct{} `type:"structure"` @@ -73469,8 +54451,7 @@ type ModifyInstancePlacementInput struct { // The name of the placement group in which to place the instance. For spread // placement groups, the instance must have a tenancy of default. For cluster - // and partition placement groups, the instance must have a tenancy of default - // or dedicated. + // placement groups, the instance must have a tenancy of default or dedicated. // // To remove an instance from a placement group, specify an empty string (""). GroupName *string `type:"string"` @@ -73483,9 +54464,6 @@ type ModifyInstancePlacementInput struct { // InstanceId is a required field InstanceId *string `locationName:"instanceId" type:"string" required:"true"` - // Reserved for future use. - PartitionNumber *int64 `type:"integer"` - // The tenancy for the instance. Tenancy *string `locationName:"tenancy" type:"string" enum:"HostTenancy"` } @@ -73537,18 +54515,13 @@ func (s *ModifyInstancePlacementInput) SetInstanceId(v string) *ModifyInstancePl return s } -// SetPartitionNumber sets the PartitionNumber field's value. -func (s *ModifyInstancePlacementInput) SetPartitionNumber(v int64) *ModifyInstancePlacementInput { - s.PartitionNumber = &v - return s -} - // SetTenancy sets the Tenancy field's value. func (s *ModifyInstancePlacementInput) SetTenancy(v string) *ModifyInstancePlacementInput { s.Tenancy = &v return s } +// Contains the output of ModifyInstancePlacement. type ModifyInstancePlacementOutput struct { _ struct{} `type:"structure"` @@ -73576,9 +54549,7 @@ type ModifyLaunchTemplateInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). - // - // Constraint: Maximum 128 ASCII characters. + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string"` // The version number of the launch template to set as the default version. @@ -73706,7 +54677,7 @@ type ModifyNetworkInterfaceAttributeInput struct { // Indicates whether source/destination checking is enabled. A value of true // means checking is enabled, and false means checking is disabled. This value // must be false for a NAT instance to perform NAT. For more information, see - // NAT Instances (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) + // NAT Instances (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html) // in the Amazon Virtual Private Cloud User Guide. SourceDestCheck *AttributeBooleanValue `locationName:"sourceDestCheck" type:"structure"` } @@ -73789,7 +54760,7 @@ type ModifyReservedInstancesInput struct { _ struct{} `type:"structure"` // A unique, case-sensitive token you provide to ensure idempotency of your - // modification request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // modification request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `locationName:"clientToken" type:"string"` // The IDs of the Reserved Instances to modify. @@ -73991,9 +54962,6 @@ type ModifySpotFleetRequestInput struct { // the Spot Fleet. ExcessCapacityTerminationPolicy *string `locationName:"excessCapacityTerminationPolicy" type:"string" enum:"ExcessCapacityTerminationPolicy"` - // The number of On-Demand Instances in the fleet. - OnDemandTargetCapacity *int64 `type:"integer"` - // The ID of the Spot Fleet request. // // SpotFleetRequestId is a required field @@ -74032,12 +55000,6 @@ func (s *ModifySpotFleetRequestInput) SetExcessCapacityTerminationPolicy(v strin return s } -// SetOnDemandTargetCapacity sets the OnDemandTargetCapacity field's value. -func (s *ModifySpotFleetRequestInput) SetOnDemandTargetCapacity(v int64) *ModifySpotFleetRequestInput { - s.OnDemandTargetCapacity = &v - return s -} - // SetSpotFleetRequestId sets the SpotFleetRequestId field's value. func (s *ModifySpotFleetRequestInput) SetSpotFleetRequestId(v string) *ModifySpotFleetRequestInput { s.SpotFleetRequestId = &v @@ -74074,6 +55036,7 @@ func (s *ModifySpotFleetRequestOutput) SetReturn(v bool) *ModifySpotFleetRequest return s } +// Contains the parameters for ModifySubnetAttribute. type ModifySubnetAttributeInput struct { _ struct{} `type:"structure"` @@ -74087,8 +55050,10 @@ type ModifySubnetAttributeInput struct { // or later of the Amazon EC2 API. AssignIpv6AddressOnCreation *AttributeBooleanValue `type:"structure"` - // Specify true to indicate that ENIs attached to instances created in the specified - // subnet should be assigned a public IPv4 address. + // Specify true to indicate that network interfaces created in the specified + // subnet should be assigned a public IPv4 address. This includes a network + // interface that's created when launching an instance into the subnet (the + // instance therefore receives a public IPv4 address). MapPublicIpOnLaunch *AttributeBooleanValue `type:"structure"` // The ID of the subnet. @@ -74152,547 +55117,6 @@ func (s ModifySubnetAttributeOutput) GoString() string { return s.String() } -type ModifyTrafficMirrorFilterNetworkServicesInput struct { - _ struct{} `type:"structure"` - - // The network service, for example Amazon DNS, that you want to mirror. - AddNetworkServices []*string `locationName:"AddNetworkService" locationNameList:"item" type:"list"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The network service, for example Amazon DNS, that you no longer want to mirror. - RemoveNetworkServices []*string `locationName:"RemoveNetworkService" locationNameList:"item" type:"list"` - - // The ID of the Traffic Mirror filter. - // - // TrafficMirrorFilterId is a required field - TrafficMirrorFilterId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorFilterNetworkServicesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorFilterNetworkServicesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyTrafficMirrorFilterNetworkServicesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyTrafficMirrorFilterNetworkServicesInput"} - if s.TrafficMirrorFilterId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAddNetworkServices sets the AddNetworkServices field's value. -func (s *ModifyTrafficMirrorFilterNetworkServicesInput) SetAddNetworkServices(v []*string) *ModifyTrafficMirrorFilterNetworkServicesInput { - s.AddNetworkServices = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyTrafficMirrorFilterNetworkServicesInput) SetDryRun(v bool) *ModifyTrafficMirrorFilterNetworkServicesInput { - s.DryRun = &v - return s -} - -// SetRemoveNetworkServices sets the RemoveNetworkServices field's value. -func (s *ModifyTrafficMirrorFilterNetworkServicesInput) SetRemoveNetworkServices(v []*string) *ModifyTrafficMirrorFilterNetworkServicesInput { - s.RemoveNetworkServices = v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *ModifyTrafficMirrorFilterNetworkServicesInput) SetTrafficMirrorFilterId(v string) *ModifyTrafficMirrorFilterNetworkServicesInput { - s.TrafficMirrorFilterId = &v - return s -} - -type ModifyTrafficMirrorFilterNetworkServicesOutput struct { - _ struct{} `type:"structure"` - - // The Traffic Mirror filter that the network service is associated with. - TrafficMirrorFilter *TrafficMirrorFilter `locationName:"trafficMirrorFilter" type:"structure"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorFilterNetworkServicesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorFilterNetworkServicesOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorFilter sets the TrafficMirrorFilter field's value. -func (s *ModifyTrafficMirrorFilterNetworkServicesOutput) SetTrafficMirrorFilter(v *TrafficMirrorFilter) *ModifyTrafficMirrorFilterNetworkServicesOutput { - s.TrafficMirrorFilter = v - return s -} - -type ModifyTrafficMirrorFilterRuleInput struct { - _ struct{} `type:"structure"` - - // The description to assign to the Traffic Mirror rule. - Description *string `type:"string"` - - // The destination CIDR block to assign to the Traffic Mirror rule. - DestinationCidrBlock *string `type:"string"` - - // The destination ports that are associated with the Traffic Mirror rule. - DestinationPortRange *TrafficMirrorPortRangeRequest `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The protocol, for example TCP, to assign to the Traffic Mirror rule. - Protocol *int64 `type:"integer"` - - // The properties that you want to remove from the Traffic Mirror filter rule. - // - // When you remove a property from a Traffic Mirror filter rule, the property - // is set to the default. - RemoveFields []*string `locationName:"RemoveField" type:"list"` - - // The action to assign to the rule. - RuleAction *string `type:"string" enum:"TrafficMirrorRuleAction"` - - // The number of the Traffic Mirror rule. This number must be unique for each - // Traffic Mirror rule in a given direction. The rules are processed in ascending - // order by rule number. - RuleNumber *int64 `type:"integer"` - - // The source CIDR block to assign to the Traffic Mirror rule. - SourceCidrBlock *string `type:"string"` - - // The port range to assign to the Traffic Mirror rule. - SourcePortRange *TrafficMirrorPortRangeRequest `type:"structure"` - - // The type of traffic (ingress | egress) to assign to the rule. - TrafficDirection *string `type:"string" enum:"TrafficDirection"` - - // The ID of the Traffic Mirror rule. - // - // TrafficMirrorFilterRuleId is a required field - TrafficMirrorFilterRuleId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorFilterRuleInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorFilterRuleInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyTrafficMirrorFilterRuleInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyTrafficMirrorFilterRuleInput"} - if s.TrafficMirrorFilterRuleId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorFilterRuleId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDescription sets the Description field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetDescription(v string) *ModifyTrafficMirrorFilterRuleInput { - s.Description = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetDestinationCidrBlock(v string) *ModifyTrafficMirrorFilterRuleInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDestinationPortRange sets the DestinationPortRange field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetDestinationPortRange(v *TrafficMirrorPortRangeRequest) *ModifyTrafficMirrorFilterRuleInput { - s.DestinationPortRange = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetDryRun(v bool) *ModifyTrafficMirrorFilterRuleInput { - s.DryRun = &v - return s -} - -// SetProtocol sets the Protocol field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetProtocol(v int64) *ModifyTrafficMirrorFilterRuleInput { - s.Protocol = &v - return s -} - -// SetRemoveFields sets the RemoveFields field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetRemoveFields(v []*string) *ModifyTrafficMirrorFilterRuleInput { - s.RemoveFields = v - return s -} - -// SetRuleAction sets the RuleAction field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetRuleAction(v string) *ModifyTrafficMirrorFilterRuleInput { - s.RuleAction = &v - return s -} - -// SetRuleNumber sets the RuleNumber field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetRuleNumber(v int64) *ModifyTrafficMirrorFilterRuleInput { - s.RuleNumber = &v - return s -} - -// SetSourceCidrBlock sets the SourceCidrBlock field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetSourceCidrBlock(v string) *ModifyTrafficMirrorFilterRuleInput { - s.SourceCidrBlock = &v - return s -} - -// SetSourcePortRange sets the SourcePortRange field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetSourcePortRange(v *TrafficMirrorPortRangeRequest) *ModifyTrafficMirrorFilterRuleInput { - s.SourcePortRange = v - return s -} - -// SetTrafficDirection sets the TrafficDirection field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetTrafficDirection(v string) *ModifyTrafficMirrorFilterRuleInput { - s.TrafficDirection = &v - return s -} - -// SetTrafficMirrorFilterRuleId sets the TrafficMirrorFilterRuleId field's value. -func (s *ModifyTrafficMirrorFilterRuleInput) SetTrafficMirrorFilterRuleId(v string) *ModifyTrafficMirrorFilterRuleInput { - s.TrafficMirrorFilterRuleId = &v - return s -} - -type ModifyTrafficMirrorFilterRuleOutput struct { - _ struct{} `type:"structure"` - - // Modifies a Traffic Mirror rule. - TrafficMirrorFilterRule *TrafficMirrorFilterRule `locationName:"trafficMirrorFilterRule" type:"structure"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorFilterRuleOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorFilterRuleOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorFilterRule sets the TrafficMirrorFilterRule field's value. -func (s *ModifyTrafficMirrorFilterRuleOutput) SetTrafficMirrorFilterRule(v *TrafficMirrorFilterRule) *ModifyTrafficMirrorFilterRuleOutput { - s.TrafficMirrorFilterRule = v - return s -} - -type ModifyTrafficMirrorSessionInput struct { - _ struct{} `type:"structure"` - - // The description to assign to the Traffic Mirror session. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The number of bytes in each packet to mirror. These are bytes after the VXLAN - // header. To mirror a subset, set this to the length (in bytes) to mirror. - // For example, if you set this value to 100, then the first 100 bytes that - // meet the filter criteria are copied to the target. Do not specify this parameter - // when you want to mirror the entire packet. - PacketLength *int64 `type:"integer"` - - // The properties that you want to remove from the Traffic Mirror session. - // - // When you remove a property from a Traffic Mirror session, the property is - // set to the default. - RemoveFields []*string `locationName:"RemoveField" type:"list"` - - // The session number determines the order in which sessions are evaluated when - // an interface is used by multiple sessions. The first session with a matching - // filter is the one that mirrors the packets. - // - // Valid values are 1-32766. - SessionNumber *int64 `type:"integer"` - - // The ID of the Traffic Mirror filter. - TrafficMirrorFilterId *string `type:"string"` - - // The ID of the Traffic Mirror session. - // - // TrafficMirrorSessionId is a required field - TrafficMirrorSessionId *string `type:"string" required:"true"` - - // The Traffic Mirror target. The target must be in the same VPC as the source, - // or have a VPC peering connection with the source. - TrafficMirrorTargetId *string `type:"string"` - - // The virtual network ID of the Traffic Mirror session. - VirtualNetworkId *int64 `type:"integer"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorSessionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorSessionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyTrafficMirrorSessionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyTrafficMirrorSessionInput"} - if s.TrafficMirrorSessionId == nil { - invalidParams.Add(request.NewErrParamRequired("TrafficMirrorSessionId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDescription sets the Description field's value. -func (s *ModifyTrafficMirrorSessionInput) SetDescription(v string) *ModifyTrafficMirrorSessionInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyTrafficMirrorSessionInput) SetDryRun(v bool) *ModifyTrafficMirrorSessionInput { - s.DryRun = &v - return s -} - -// SetPacketLength sets the PacketLength field's value. -func (s *ModifyTrafficMirrorSessionInput) SetPacketLength(v int64) *ModifyTrafficMirrorSessionInput { - s.PacketLength = &v - return s -} - -// SetRemoveFields sets the RemoveFields field's value. -func (s *ModifyTrafficMirrorSessionInput) SetRemoveFields(v []*string) *ModifyTrafficMirrorSessionInput { - s.RemoveFields = v - return s -} - -// SetSessionNumber sets the SessionNumber field's value. -func (s *ModifyTrafficMirrorSessionInput) SetSessionNumber(v int64) *ModifyTrafficMirrorSessionInput { - s.SessionNumber = &v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *ModifyTrafficMirrorSessionInput) SetTrafficMirrorFilterId(v string) *ModifyTrafficMirrorSessionInput { - s.TrafficMirrorFilterId = &v - return s -} - -// SetTrafficMirrorSessionId sets the TrafficMirrorSessionId field's value. -func (s *ModifyTrafficMirrorSessionInput) SetTrafficMirrorSessionId(v string) *ModifyTrafficMirrorSessionInput { - s.TrafficMirrorSessionId = &v - return s -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *ModifyTrafficMirrorSessionInput) SetTrafficMirrorTargetId(v string) *ModifyTrafficMirrorSessionInput { - s.TrafficMirrorTargetId = &v - return s -} - -// SetVirtualNetworkId sets the VirtualNetworkId field's value. -func (s *ModifyTrafficMirrorSessionInput) SetVirtualNetworkId(v int64) *ModifyTrafficMirrorSessionInput { - s.VirtualNetworkId = &v - return s -} - -type ModifyTrafficMirrorSessionOutput struct { - _ struct{} `type:"structure"` - - // Information about the Traffic Mirror session. - TrafficMirrorSession *TrafficMirrorSession `locationName:"trafficMirrorSession" type:"structure"` -} - -// String returns the string representation -func (s ModifyTrafficMirrorSessionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTrafficMirrorSessionOutput) GoString() string { - return s.String() -} - -// SetTrafficMirrorSession sets the TrafficMirrorSession field's value. -func (s *ModifyTrafficMirrorSessionOutput) SetTrafficMirrorSession(v *TrafficMirrorSession) *ModifyTrafficMirrorSessionOutput { - s.TrafficMirrorSession = v - return s -} - -type ModifyTransitGatewayVpcAttachmentInput struct { - _ struct{} `type:"structure"` - - // The IDs of one or more subnets to add. You can specify at most one subnet - // per Availability Zone. - AddSubnetIds []*string `locationNameList:"item" type:"list"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The new VPC attachment options. - Options *ModifyTransitGatewayVpcAttachmentRequestOptions `type:"structure"` - - // The IDs of one or more subnets to remove. - RemoveSubnetIds []*string `locationNameList:"item" type:"list"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ModifyTransitGatewayVpcAttachmentInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTransitGatewayVpcAttachmentInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyTransitGatewayVpcAttachmentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyTransitGatewayVpcAttachmentInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAddSubnetIds sets the AddSubnetIds field's value. -func (s *ModifyTransitGatewayVpcAttachmentInput) SetAddSubnetIds(v []*string) *ModifyTransitGatewayVpcAttachmentInput { - s.AddSubnetIds = v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyTransitGatewayVpcAttachmentInput) SetDryRun(v bool) *ModifyTransitGatewayVpcAttachmentInput { - s.DryRun = &v - return s -} - -// SetOptions sets the Options field's value. -func (s *ModifyTransitGatewayVpcAttachmentInput) SetOptions(v *ModifyTransitGatewayVpcAttachmentRequestOptions) *ModifyTransitGatewayVpcAttachmentInput { - s.Options = v - return s -} - -// SetRemoveSubnetIds sets the RemoveSubnetIds field's value. -func (s *ModifyTransitGatewayVpcAttachmentInput) SetRemoveSubnetIds(v []*string) *ModifyTransitGatewayVpcAttachmentInput { - s.RemoveSubnetIds = v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *ModifyTransitGatewayVpcAttachmentInput) SetTransitGatewayAttachmentId(v string) *ModifyTransitGatewayVpcAttachmentInput { - s.TransitGatewayAttachmentId = &v - return s -} - -type ModifyTransitGatewayVpcAttachmentOutput struct { - _ struct{} `type:"structure"` - - // Information about the modified attachment. - TransitGatewayVpcAttachment *TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachment" type:"structure"` -} - -// String returns the string representation -func (s ModifyTransitGatewayVpcAttachmentOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTransitGatewayVpcAttachmentOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayVpcAttachment sets the TransitGatewayVpcAttachment field's value. -func (s *ModifyTransitGatewayVpcAttachmentOutput) SetTransitGatewayVpcAttachment(v *TransitGatewayVpcAttachment) *ModifyTransitGatewayVpcAttachmentOutput { - s.TransitGatewayVpcAttachment = v - return s -} - -// Describes the options for a VPC attachment. -type ModifyTransitGatewayVpcAttachmentRequestOptions struct { - _ struct{} `type:"structure"` - - // Enable or disable DNS support. The default is enable. - DnsSupport *string `type:"string" enum:"DnsSupportValue"` - - // Enable or disable IPv6 support. The default is enable. - Ipv6Support *string `type:"string" enum:"Ipv6SupportValue"` -} - -// String returns the string representation -func (s ModifyTransitGatewayVpcAttachmentRequestOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyTransitGatewayVpcAttachmentRequestOptions) GoString() string { - return s.String() -} - -// SetDnsSupport sets the DnsSupport field's value. -func (s *ModifyTransitGatewayVpcAttachmentRequestOptions) SetDnsSupport(v string) *ModifyTransitGatewayVpcAttachmentRequestOptions { - s.DnsSupport = &v - return s -} - -// SetIpv6Support sets the Ipv6Support field's value. -func (s *ModifyTransitGatewayVpcAttachmentRequestOptions) SetIpv6Support(v string) *ModifyTransitGatewayVpcAttachmentRequestOptions { - s.Ipv6Support = &v - return s -} - // Contains the parameters for ModifyVolumeAttribute. type ModifyVolumeAttributeInput struct { _ struct{} `type:"structure"` @@ -74779,14 +55203,14 @@ type ModifyVolumeInput struct { // The target IOPS rate of the volume. // // This is only valid for Provisioned IOPS SSD (io1) volumes. For more information, - // see Provisioned IOPS SSD (io1) Volumes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html#EBSVolumeTypes_piops). + // see Provisioned IOPS SSD (io1) Volumes (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html#EBSVolumeTypes_piops). // // Default: If no IOPS value is specified, the existing value is retained. Iops *int64 `type:"integer"` // The target size of the volume, in GiB. The target volume size must be greater // than or equal to than the existing size of the volume. For information about - // available EBS volume sizes, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html). + // available EBS volume sizes, see Amazon EBS Volume Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html). // // Default: If no size is specified, the existing size is retained. Size *int64 `type:"integer"` @@ -74878,6 +55302,7 @@ func (s *ModifyVolumeOutput) SetVolumeModification(v *VolumeModification) *Modif return s } +// Contains the parameters for ModifyVpcAttribute. type ModifyVpcAttributeInput struct { _ struct{} `type:"structure"` @@ -75072,9 +55497,8 @@ type ModifyVpcEndpointInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // A policy to attach to the endpoint that controls access to the service. The - // policy must be in valid JSON format. If this parameter is not specified, - // we attach a default policy that allows full access to the service. + // (Gateway endpoint) A policy document to attach to the endpoint. The policy + // must be in valid JSON format. PolicyDocument *string `type:"string"` // (Interface endpoint) Indicate whether a private hosted zone is associated @@ -75415,7 +55839,7 @@ type ModifyVpcPeeringConnectionOptionsInput struct { // The VPC peering connection options for the accepter VPC. AccepterPeeringConnectionOptions *PeeringConnectionOptionsRequest `type:"structure"` - // Checks whether you have the required permissions for the action, without + // Checks whether you have the required permissions for the operation, without // actually making the request, and provides an error response. If you have // the required permissions, the error response is DryRunOperation. Otherwise, // it is UnauthorizedOperation. @@ -75509,10 +55933,11 @@ func (s *ModifyVpcPeeringConnectionOptionsOutput) SetRequesterPeeringConnectionO return s } +// Contains the parameters for ModifyVpcTenancy. type ModifyVpcTenancyInput struct { _ struct{} `type:"structure"` - // Checks whether you have the required permissions for the action, without + // Checks whether you have the required permissions for the operation, without // actually making the request, and provides an error response. If you have // the required permissions, the error response is DryRunOperation. Otherwise, // it is UnauthorizedOperation. @@ -75573,6 +55998,7 @@ func (s *ModifyVpcTenancyInput) SetVpcId(v string) *ModifyVpcTenancyInput { return s } +// Contains the output of ModifyVpcTenancy. type ModifyVpcTenancyOutput struct { _ struct{} `type:"structure"` @@ -75596,97 +56022,7 @@ func (s *ModifyVpcTenancyOutput) SetReturnValue(v bool) *ModifyVpcTenancyOutput return s } -type ModifyVpnConnectionInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the transit gateway. - TransitGatewayId *string `type:"string"` - - // The ID of the VPN connection. - // - // VpnConnectionId is a required field - VpnConnectionId *string `type:"string" required:"true"` - - // The ID of the virtual private gateway at the AWS side of the VPN connection. - VpnGatewayId *string `type:"string"` -} - -// String returns the string representation -func (s ModifyVpnConnectionInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyVpnConnectionInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ModifyVpnConnectionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ModifyVpnConnectionInput"} - if s.VpnConnectionId == nil { - invalidParams.Add(request.NewErrParamRequired("VpnConnectionId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *ModifyVpnConnectionInput) SetDryRun(v bool) *ModifyVpnConnectionInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *ModifyVpnConnectionInput) SetTransitGatewayId(v string) *ModifyVpnConnectionInput { - s.TransitGatewayId = &v - return s -} - -// SetVpnConnectionId sets the VpnConnectionId field's value. -func (s *ModifyVpnConnectionInput) SetVpnConnectionId(v string) *ModifyVpnConnectionInput { - s.VpnConnectionId = &v - return s -} - -// SetVpnGatewayId sets the VpnGatewayId field's value. -func (s *ModifyVpnConnectionInput) SetVpnGatewayId(v string) *ModifyVpnConnectionInput { - s.VpnGatewayId = &v - return s -} - -type ModifyVpnConnectionOutput struct { - _ struct{} `type:"structure"` - - // Describes a VPN connection. - VpnConnection *VpnConnection `locationName:"vpnConnection" type:"structure"` -} - -// String returns the string representation -func (s ModifyVpnConnectionOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ModifyVpnConnectionOutput) GoString() string { - return s.String() -} - -// SetVpnConnection sets the VpnConnection field's value. -func (s *ModifyVpnConnectionOutput) SetVpnConnection(v *VpnConnection) *ModifyVpnConnectionOutput { - s.VpnConnection = v - return s -} - +// Contains the parameters for MonitorInstances. type MonitorInstancesInput struct { _ struct{} `type:"structure"` @@ -75696,7 +56032,7 @@ type MonitorInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the instances. + // One or more instance IDs. // // InstanceIds is a required field InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` @@ -75737,6 +56073,7 @@ func (s *MonitorInstancesInput) SetInstanceIds(v []*string) *MonitorInstancesInp return s } +// Contains the output of MonitorInstances. type MonitorInstancesOutput struct { _ struct{} `type:"structure"` @@ -75785,6 +56122,7 @@ func (s *Monitoring) SetState(v string) *Monitoring { return s } +// Contains the parameters for MoveAddressToVpc. type MoveAddressToVpcInput struct { _ struct{} `type:"structure"` @@ -75835,6 +56173,7 @@ func (s *MoveAddressToVpcInput) SetPublicIp(v string) *MoveAddressToVpcInput { return s } +// Contains the output of MoveAddressToVpc. type MoveAddressToVpcOutput struct { _ struct{} `type:"structure"` @@ -75946,7 +56285,7 @@ type NatGateway struct { NatGatewayId *string `locationName:"natGatewayId" type:"string"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). ProvisionedBandwidth *ProvisionedBandwidth `locationName:"provisionedBandwidth" type:"structure"` @@ -76123,9 +56462,6 @@ type NetworkAcl struct { // The ID of the network ACL. NetworkAclId *string `locationName:"networkAclId" type:"string"` - // The ID of the AWS account that owns the network ACL. - OwnerId *string `locationName:"ownerId" type:"string"` - // Any tags assigned to the network ACL. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` @@ -76167,12 +56503,6 @@ func (s *NetworkAcl) SetNetworkAclId(v string) *NetworkAcl { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *NetworkAcl) SetOwnerId(v string) *NetworkAcl { - s.OwnerId = &v - return s -} - // SetTags sets the Tags field's value. func (s *NetworkAcl) SetTags(v []*Tag) *NetworkAcl { s.Tags = v @@ -76247,7 +56577,7 @@ type NetworkAclEntry struct { // TCP or UDP protocols: The range of ports the rule applies to. PortRange *PortRange `locationName:"portRange" type:"structure"` - // The protocol number. A value of "-1" means all protocols. + // The protocol. A value of -1 means all protocols. Protocol *string `locationName:"protocol" type:"string"` // Indicates whether to allow or deny the traffic that matches the rule. @@ -76336,7 +56666,7 @@ type NetworkInterface struct { // Any security groups for the network interface. Groups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"` - // The type of network interface. + // The type of interface. InterfaceType *string `locationName:"interfaceType" type:"string" enum:"NetworkInterfaceType"` // The IPv6 addresses associated with the network interface. @@ -76893,7 +57223,7 @@ func (s *NewDhcpConfiguration) SetValues(v []*string) *NewDhcpConfiguration { return s } -// Describes the configuration of On-Demand Instances in an EC2 Fleet. +// The allocation strategy of On-Demand Instances in an EC2 Fleet. type OnDemandOptions struct { _ struct{} `type:"structure"` @@ -76904,22 +57234,6 @@ type OnDemandOptions struct { // launching the highest priority first. If you do not specify a value, EC2 // Fleet defaults to lowest-price. AllocationStrategy *string `locationName:"allocationStrategy" type:"string" enum:"FleetOnDemandAllocationStrategy"` - - // The maximum amount per hour for On-Demand Instances that you're willing to - // pay. - MaxTotalPrice *string `locationName:"maxTotalPrice" type:"string"` - - // The minimum target capacity for On-Demand Instances in the fleet. If the - // minimum target capacity is not reached, the fleet launches no instances. - MinTargetCapacity *int64 `locationName:"minTargetCapacity" type:"integer"` - - // Indicates that the fleet launches all On-Demand Instances into a single Availability - // Zone. - SingleAvailabilityZone *bool `locationName:"singleAvailabilityZone" type:"boolean"` - - // Indicates that the fleet uses a single instance type to launch all On-Demand - // Instances in the fleet. - SingleInstanceType *bool `locationName:"singleInstanceType" type:"boolean"` } // String returns the string representation @@ -76938,31 +57252,7 @@ func (s *OnDemandOptions) SetAllocationStrategy(v string) *OnDemandOptions { return s } -// SetMaxTotalPrice sets the MaxTotalPrice field's value. -func (s *OnDemandOptions) SetMaxTotalPrice(v string) *OnDemandOptions { - s.MaxTotalPrice = &v - return s -} - -// SetMinTargetCapacity sets the MinTargetCapacity field's value. -func (s *OnDemandOptions) SetMinTargetCapacity(v int64) *OnDemandOptions { - s.MinTargetCapacity = &v - return s -} - -// SetSingleAvailabilityZone sets the SingleAvailabilityZone field's value. -func (s *OnDemandOptions) SetSingleAvailabilityZone(v bool) *OnDemandOptions { - s.SingleAvailabilityZone = &v - return s -} - -// SetSingleInstanceType sets the SingleInstanceType field's value. -func (s *OnDemandOptions) SetSingleInstanceType(v bool) *OnDemandOptions { - s.SingleInstanceType = &v - return s -} - -// Describes the configuration of On-Demand Instances in an EC2 Fleet. +// The allocation strategy of On-Demand Instances in an EC2 Fleet. type OnDemandOptionsRequest struct { _ struct{} `type:"structure"` @@ -76973,22 +57263,6 @@ type OnDemandOptionsRequest struct { // launching the highest priority first. If you do not specify a value, EC2 // Fleet defaults to lowest-price. AllocationStrategy *string `type:"string" enum:"FleetOnDemandAllocationStrategy"` - - // The maximum amount per hour for On-Demand Instances that you're willing to - // pay. - MaxTotalPrice *string `type:"string"` - - // The minimum target capacity for On-Demand Instances in the fleet. If the - // minimum target capacity is not reached, the fleet launches no instances. - MinTargetCapacity *int64 `type:"integer"` - - // Indicates that the fleet launches all On-Demand Instances into a single Availability - // Zone. - SingleAvailabilityZone *bool `type:"boolean"` - - // Indicates that the fleet uses a single instance type to launch all On-Demand - // Instances in the fleet. - SingleInstanceType *bool `type:"boolean"` } // String returns the string representation @@ -77007,30 +57281,6 @@ func (s *OnDemandOptionsRequest) SetAllocationStrategy(v string) *OnDemandOption return s } -// SetMaxTotalPrice sets the MaxTotalPrice field's value. -func (s *OnDemandOptionsRequest) SetMaxTotalPrice(v string) *OnDemandOptionsRequest { - s.MaxTotalPrice = &v - return s -} - -// SetMinTargetCapacity sets the MinTargetCapacity field's value. -func (s *OnDemandOptionsRequest) SetMinTargetCapacity(v int64) *OnDemandOptionsRequest { - s.MinTargetCapacity = &v - return s -} - -// SetSingleAvailabilityZone sets the SingleAvailabilityZone field's value. -func (s *OnDemandOptionsRequest) SetSingleAvailabilityZone(v bool) *OnDemandOptionsRequest { - s.SingleAvailabilityZone = &v - return s -} - -// SetSingleInstanceType sets the SingleInstanceType field's value. -func (s *OnDemandOptionsRequest) SetSingleInstanceType(v bool) *OnDemandOptionsRequest { - s.SingleInstanceType = &v - return s -} - // Describes the data that identifies an Amazon FPGA image (AFI) on the PCI // bus. type PciId struct { @@ -77092,11 +57342,11 @@ type PeeringConnectionOptions struct { AllowDnsResolutionFromRemoteVpc *bool `locationName:"allowDnsResolutionFromRemoteVpc" type:"boolean"` // If true, enables outbound communication from an EC2-Classic instance that's - // linked to a local VPC using ClassicLink to instances in a peer VPC. + // linked to a local VPC via ClassicLink to instances in a peer VPC. AllowEgressFromLocalClassicLinkToRemoteVpc *bool `locationName:"allowEgressFromLocalClassicLinkToRemoteVpc" type:"boolean"` // If true, enables outbound communication from instances in a local VPC to - // an EC2-Classic instance that's linked to a peer VPC using ClassicLink. + // an EC2-Classic instance that's linked to a peer VPC via ClassicLink. AllowEgressFromLocalVpcToRemoteClassicLink *bool `locationName:"allowEgressFromLocalVpcToRemoteClassicLink" type:"boolean"` } @@ -77137,11 +57387,11 @@ type PeeringConnectionOptionsRequest struct { AllowDnsResolutionFromRemoteVpc *bool `type:"boolean"` // If true, enables outbound communication from an EC2-Classic instance that's - // linked to a local VPC using ClassicLink to instances in a peer VPC. + // linked to a local VPC via ClassicLink to instances in a peer VPC. AllowEgressFromLocalClassicLinkToRemoteVpc *bool `type:"boolean"` // If true, enables outbound communication from instances in a local VPC to - // an EC2-Classic instance that's linked to a peer VPC using ClassicLink. + // an EC2-Classic instance that's linked to a peer VPC via ClassicLink. AllowEgressFromLocalVpcToRemoteClassicLink *bool `type:"boolean"` } @@ -77182,9 +57432,6 @@ type Placement struct { Affinity *string `locationName:"affinity" type:"string"` // The Availability Zone of the instance. - // - // If not specified, an Availability Zone will be automatically chosen for you - // based on the load balancing criteria for the Region. AvailabilityZone *string `locationName:"availabilityZone" type:"string"` // The name of the placement group the instance is in. @@ -77194,10 +57441,6 @@ type Placement struct { // is not supported for the ImportInstance command. HostId *string `locationName:"hostId" type:"string"` - // The number of the partition the instance is in. Valid only if the placement - // group strategy is set to partition. - PartitionNumber *int64 `locationName:"partitionNumber" type:"integer"` - // Reserved for future use. SpreadDomain *string `locationName:"spreadDomain" type:"string"` @@ -77241,12 +57484,6 @@ func (s *Placement) SetHostId(v string) *Placement { return s } -// SetPartitionNumber sets the PartitionNumber field's value. -func (s *Placement) SetPartitionNumber(v int64) *Placement { - s.PartitionNumber = &v - return s -} - // SetSpreadDomain sets the SpreadDomain field's value. func (s *Placement) SetSpreadDomain(v string) *Placement { s.SpreadDomain = &v @@ -77266,9 +57503,6 @@ type PlacementGroup struct { // The name of the placement group. GroupName *string `locationName:"groupName" type:"string"` - // The number of partitions. Valid only if strategy is set to partition. - PartitionCount *int64 `locationName:"partitionCount" type:"integer"` - // The state of the placement group. State *string `locationName:"state" type:"string" enum:"PlacementGroupState"` @@ -77292,12 +57526,6 @@ func (s *PlacementGroup) SetGroupName(v string) *PlacementGroup { return s } -// SetPartitionCount sets the PartitionCount field's value. -func (s *PlacementGroup) SetPartitionCount(v int64) *PlacementGroup { - s.PartitionCount = &v - return s -} - // SetState sets the State field's value. func (s *PlacementGroup) SetState(v string) *PlacementGroup { s.State = &v @@ -77310,30 +57538,6 @@ func (s *PlacementGroup) SetStrategy(v string) *PlacementGroup { return s } -// Describes the placement of an instance. -type PlacementResponse struct { - _ struct{} `type:"structure"` - - // The name of the placement group the instance is in. - GroupName *string `locationName:"groupName" type:"string"` -} - -// String returns the string representation -func (s PlacementResponse) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s PlacementResponse) GoString() string { - return s.String() -} - -// SetGroupName sets the GroupName field's value. -func (s *PlacementResponse) SetGroupName(v string) *PlacementResponse { - s.GroupName = &v - return s -} - // Describes a range of ports. type PortRange struct { _ struct{} `type:"structure"` @@ -77409,7 +57613,7 @@ func (s *PrefixList) SetPrefixListName(v string) *PrefixList { return s } -// Describes a prefix list ID. +// [EC2-VPC only] The ID of the prefix. type PrefixListId struct { _ struct{} `type:"structure"` @@ -77709,133 +57913,34 @@ func (s *PropagatingVgw) SetGatewayId(v string) *PropagatingVgw { return s } -type ProvisionByoipCidrInput struct { - _ struct{} `type:"structure"` - - // The public IPv4 address range, in CIDR notation. The most specific prefix - // that you can specify is /24. The address range cannot overlap with another - // address range that you've brought to this or another Region. - // - // Cidr is a required field - Cidr *string `type:"string" required:"true"` - - // A signed document that proves that you are authorized to bring the specified - // IP address range to Amazon using BYOIP. - CidrAuthorizationContext *CidrAuthorizationContext `type:"structure"` - - // A description for the address range and the address pool. - Description *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s ProvisionByoipCidrInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ProvisionByoipCidrInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ProvisionByoipCidrInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ProvisionByoipCidrInput"} - if s.Cidr == nil { - invalidParams.Add(request.NewErrParamRequired("Cidr")) - } - if s.CidrAuthorizationContext != nil { - if err := s.CidrAuthorizationContext.Validate(); err != nil { - invalidParams.AddNested("CidrAuthorizationContext", err.(request.ErrInvalidParams)) - } - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCidr sets the Cidr field's value. -func (s *ProvisionByoipCidrInput) SetCidr(v string) *ProvisionByoipCidrInput { - s.Cidr = &v - return s -} - -// SetCidrAuthorizationContext sets the CidrAuthorizationContext field's value. -func (s *ProvisionByoipCidrInput) SetCidrAuthorizationContext(v *CidrAuthorizationContext) *ProvisionByoipCidrInput { - s.CidrAuthorizationContext = v - return s -} - -// SetDescription sets the Description field's value. -func (s *ProvisionByoipCidrInput) SetDescription(v string) *ProvisionByoipCidrInput { - s.Description = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ProvisionByoipCidrInput) SetDryRun(v bool) *ProvisionByoipCidrInput { - s.DryRun = &v - return s -} - -type ProvisionByoipCidrOutput struct { - _ struct{} `type:"structure"` - - // Information about the address pool. - ByoipCidr *ByoipCidr `locationName:"byoipCidr" type:"structure"` -} - -// String returns the string representation -func (s ProvisionByoipCidrOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ProvisionByoipCidrOutput) GoString() string { - return s.String() -} - -// SetByoipCidr sets the ByoipCidr field's value. -func (s *ProvisionByoipCidrOutput) SetByoipCidr(v *ByoipCidr) *ProvisionByoipCidrOutput { - s.ByoipCidr = v - return s -} - // Reserved. If you need to sustain traffic greater than the documented limits -// (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), +// (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). type ProvisionedBandwidth struct { _ struct{} `type:"structure"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). ProvisionTime *time.Time `locationName:"provisionTime" type:"timestamp"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). Provisioned *string `locationName:"provisioned" type:"string"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). RequestTime *time.Time `locationName:"requestTime" type:"timestamp"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). Requested *string `locationName:"requested" type:"string"` // Reserved. If you need to sustain traffic greater than the documented limits - // (https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html), + // (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), // contact us through the Support Center (https://console.aws.amazon.com/support/home?). Status *string `locationName:"status" type:"string"` } @@ -77880,117 +57985,6 @@ func (s *ProvisionedBandwidth) SetStatus(v string) *ProvisionedBandwidth { return s } -// Describes an address pool. -type PublicIpv4Pool struct { - _ struct{} `type:"structure"` - - // A description of the address pool. - Description *string `locationName:"description" type:"string"` - - // The address ranges. - PoolAddressRanges []*PublicIpv4PoolRange `locationName:"poolAddressRangeSet" locationNameList:"item" type:"list"` - - // The ID of the IPv4 address pool. - PoolId *string `locationName:"poolId" type:"string"` - - // The total number of addresses. - TotalAddressCount *int64 `locationName:"totalAddressCount" type:"integer"` - - // The total number of available addresses. - TotalAvailableAddressCount *int64 `locationName:"totalAvailableAddressCount" type:"integer"` -} - -// String returns the string representation -func (s PublicIpv4Pool) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s PublicIpv4Pool) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *PublicIpv4Pool) SetDescription(v string) *PublicIpv4Pool { - s.Description = &v - return s -} - -// SetPoolAddressRanges sets the PoolAddressRanges field's value. -func (s *PublicIpv4Pool) SetPoolAddressRanges(v []*PublicIpv4PoolRange) *PublicIpv4Pool { - s.PoolAddressRanges = v - return s -} - -// SetPoolId sets the PoolId field's value. -func (s *PublicIpv4Pool) SetPoolId(v string) *PublicIpv4Pool { - s.PoolId = &v - return s -} - -// SetTotalAddressCount sets the TotalAddressCount field's value. -func (s *PublicIpv4Pool) SetTotalAddressCount(v int64) *PublicIpv4Pool { - s.TotalAddressCount = &v - return s -} - -// SetTotalAvailableAddressCount sets the TotalAvailableAddressCount field's value. -func (s *PublicIpv4Pool) SetTotalAvailableAddressCount(v int64) *PublicIpv4Pool { - s.TotalAvailableAddressCount = &v - return s -} - -// Describes an address range of an IPv4 address pool. -type PublicIpv4PoolRange struct { - _ struct{} `type:"structure"` - - // The number of addresses in the range. - AddressCount *int64 `locationName:"addressCount" type:"integer"` - - // The number of available addresses in the range. - AvailableAddressCount *int64 `locationName:"availableAddressCount" type:"integer"` - - // The first IP address in the range. - FirstAddress *string `locationName:"firstAddress" type:"string"` - - // The last IP address in the range. - LastAddress *string `locationName:"lastAddress" type:"string"` -} - -// String returns the string representation -func (s PublicIpv4PoolRange) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s PublicIpv4PoolRange) GoString() string { - return s.String() -} - -// SetAddressCount sets the AddressCount field's value. -func (s *PublicIpv4PoolRange) SetAddressCount(v int64) *PublicIpv4PoolRange { - s.AddressCount = &v - return s -} - -// SetAvailableAddressCount sets the AvailableAddressCount field's value. -func (s *PublicIpv4PoolRange) SetAvailableAddressCount(v int64) *PublicIpv4PoolRange { - s.AvailableAddressCount = &v - return s -} - -// SetFirstAddress sets the FirstAddress field's value. -func (s *PublicIpv4PoolRange) SetFirstAddress(v string) *PublicIpv4PoolRange { - s.FirstAddress = &v - return s -} - -// SetLastAddress sets the LastAddress field's value. -func (s *PublicIpv4PoolRange) SetLastAddress(v string) *PublicIpv4PoolRange { - s.LastAddress = &v - return s -} - // Describes the result of the purchase. type Purchase struct { _ struct{} `type:"structure"` @@ -78083,8 +58077,9 @@ func (s *Purchase) SetUpfrontPrice(v string) *Purchase { type PurchaseHostReservationInput struct { _ struct{} `type:"structure"` - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // Unique, case-sensitive identifier you provide to ensure idempotency of the + // request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // in the Amazon Elastic Compute Cloud User Guide. ClientToken *string `type:"string"` // The currency in which the totalUpfrontPrice, LimitPrice, and totalHourlyPrice @@ -78169,8 +58164,9 @@ func (s *PurchaseHostReservationInput) SetOfferingId(v string) *PurchaseHostRese type PurchaseHostReservationOutput struct { _ struct{} `type:"structure"` - // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // Unique, case-sensitive identifier you provide to ensure idempotency of the + // request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // in the Amazon Elastic Compute Cloud User Guide. ClientToken *string `locationName:"clientToken" type:"string"` // The currency in which the totalUpfrontPrice and totalHourlyPrice amounts @@ -78385,7 +58381,7 @@ type PurchaseScheduledInstancesInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that ensures the idempotency of the request. - // For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string" idempotencyToken:"true"` // Checks whether you have the required permissions for the action, without @@ -78394,7 +58390,7 @@ type PurchaseScheduledInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `type:"boolean"` - // The purchase requests. + // One or more purchase requests. // // PurchaseRequests is a required field PurchaseRequests []*PurchaseRequest `locationName:"PurchaseRequest" locationNameList:"PurchaseRequest" min:"1" type:"list" required:"true"` @@ -78478,6 +58474,7 @@ func (s *PurchaseScheduledInstancesOutput) SetScheduledInstanceSet(v []*Schedule return s } +// Contains the parameters for RebootInstances. type RebootInstancesInput struct { _ struct{} `type:"structure"` @@ -78487,7 +58484,7 @@ type RebootInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The instance IDs. + // One or more instance IDs. // // InstanceIds is a required field InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` @@ -78575,14 +58572,14 @@ func (s *RecurringCharge) SetFrequency(v string) *RecurringCharge { return s } -// Describes a Region. +// Describes a region. type Region struct { _ struct{} `type:"structure"` - // The Region service endpoint. + // The region service endpoint. Endpoint *string `locationName:"regionEndpoint" type:"string"` - // The name of the Region. + // The name of the region. RegionName *string `locationName:"regionName" type:"string"` } @@ -78623,7 +58620,7 @@ type RegisterImageInput struct { // use of an AMI. BillingProducts []*string `locationName:"BillingProduct" locationNameList:"item" type:"list"` - // The block device mapping entries. + // One or more block device mapping entries. BlockDeviceMappings []*BlockDeviceMapping `locationName:"BlockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"` // A description for your AMI. @@ -78642,10 +58639,7 @@ type RegisterImageInput struct { // PV AMI can make instances launched from the AMI unreachable. EnaSupport *bool `locationName:"enaSupport" type:"boolean"` - // The full path to your AMI manifest in Amazon S3 storage. The specified bucket - // must have the aws-exec-read canned access control list (ACL) to ensure that - // it can be accessed by Amazon EC2. For more information, see Canned ACLs (https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl) - // in the Amazon S3 Service Developer Guide. + // The full path to your AMI manifest in Amazon S3 storage. ImageLocation *string `type:"string"` // The ID of the kernel. @@ -78807,79 +58801,6 @@ func (s *RegisterImageOutput) SetImageId(v string) *RegisterImageOutput { return s } -type RejectTransitGatewayVpcAttachmentInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - // - // TransitGatewayAttachmentId is a required field - TransitGatewayAttachmentId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s RejectTransitGatewayVpcAttachmentInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RejectTransitGatewayVpcAttachmentInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *RejectTransitGatewayVpcAttachmentInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RejectTransitGatewayVpcAttachmentInput"} - if s.TransitGatewayAttachmentId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayAttachmentId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *RejectTransitGatewayVpcAttachmentInput) SetDryRun(v bool) *RejectTransitGatewayVpcAttachmentInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *RejectTransitGatewayVpcAttachmentInput) SetTransitGatewayAttachmentId(v string) *RejectTransitGatewayVpcAttachmentInput { - s.TransitGatewayAttachmentId = &v - return s -} - -type RejectTransitGatewayVpcAttachmentOutput struct { - _ struct{} `type:"structure"` - - // Information about the attachment. - TransitGatewayVpcAttachment *TransitGatewayVpcAttachment `locationName:"transitGatewayVpcAttachment" type:"structure"` -} - -// String returns the string representation -func (s RejectTransitGatewayVpcAttachmentOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RejectTransitGatewayVpcAttachmentOutput) GoString() string { - return s.String() -} - -// SetTransitGatewayVpcAttachment sets the TransitGatewayVpcAttachment field's value. -func (s *RejectTransitGatewayVpcAttachmentOutput) SetTransitGatewayVpcAttachment(v *TransitGatewayVpcAttachment) *RejectTransitGatewayVpcAttachmentOutput { - s.TransitGatewayVpcAttachment = v - return s -} - type RejectVpcEndpointConnectionsInput struct { _ struct{} `type:"structure"` @@ -78967,6 +58888,7 @@ func (s *RejectVpcEndpointConnectionsOutput) SetUnsuccessful(v []*UnsuccessfulIt return s } +// Contains the parameters for RejectVpcPeeringConnection. type RejectVpcPeeringConnectionInput struct { _ struct{} `type:"structure"` @@ -79017,6 +58939,7 @@ func (s *RejectVpcPeeringConnectionInput) SetVpcPeeringConnectionId(v string) *R return s } +// Contains the output of RejectVpcPeeringConnection. type RejectVpcPeeringConnectionOutput struct { _ struct{} `type:"structure"` @@ -79040,6 +58963,7 @@ func (s *RejectVpcPeeringConnectionOutput) SetReturn(v bool) *RejectVpcPeeringCo return s } +// Contains the parameters for ReleaseAddress. type ReleaseAddressInput struct { _ struct{} `type:"structure"` @@ -79098,6 +59022,7 @@ func (s ReleaseAddressOutput) GoString() string { return s.String() } +// Contains the parameters for ReleaseHosts. type ReleaseHostsInput struct { _ struct{} `type:"structure"` @@ -79136,6 +59061,7 @@ func (s *ReleaseHostsInput) SetHostIds(v []*string) *ReleaseHostsInput { return s } +// Contains the output of ReleaseHosts. type ReleaseHostsOutput struct { _ struct{} `type:"structure"` @@ -79244,6 +59170,7 @@ func (s *ReplaceIamInstanceProfileAssociationOutput) SetIamInstanceProfileAssoci return s } +// Contains the parameters for ReplaceNetworkAclAssociation. type ReplaceNetworkAclAssociationInput struct { _ struct{} `type:"structure"` @@ -79309,6 +59236,7 @@ func (s *ReplaceNetworkAclAssociationInput) SetNetworkAclId(v string) *ReplaceNe return s } +// Contains the output of ReplaceNetworkAclAssociation. type ReplaceNetworkAclAssociationOutput struct { _ struct{} `type:"structure"` @@ -79332,6 +59260,7 @@ func (s *ReplaceNetworkAclAssociationOutput) SetNewAssociationId(v string) *Repl return s } +// Contains the parameters for ReplaceNetworkAclEntry. type ReplaceNetworkAclEntryInput struct { _ struct{} `type:"structure"` @@ -79351,8 +59280,8 @@ type ReplaceNetworkAclEntryInput struct { // Egress is a required field Egress *bool `locationName:"egress" type:"boolean" required:"true"` - // ICMP protocol: The ICMP or ICMPv6 type and code. Required if specifying protocol - // 1 (ICMP) or protocol 58 (ICMPv6) with an IPv6 CIDR block. + // ICMP protocol: The ICMP or ICMPv6 type and code. Required if specifying the + // ICMP (1) protocol, or protocol 58 (ICMPv6) with an IPv6 CIDR block. IcmpTypeCode *IcmpTypeCode `locationName:"Icmp" type:"structure"` // The IPv6 network range to allow or deny, in CIDR notation (for example 2001:bd8:1234:1a00::/64). @@ -79364,16 +59293,16 @@ type ReplaceNetworkAclEntryInput struct { NetworkAclId *string `locationName:"networkAclId" type:"string" required:"true"` // TCP or UDP protocols: The range of ports the rule applies to. Required if - // specifying protocol 6 (TCP) or 17 (UDP). + // specifying TCP (6) or UDP (17) for the protocol. PortRange *PortRange `locationName:"portRange" type:"structure"` - // The protocol number. A value of "-1" means all protocols. If you specify - // "-1" or a protocol number other than "6" (TCP), "17" (UDP), or "1" (ICMP), - // traffic on all ports is allowed, regardless of any ports or ICMP types or - // codes that you specify. If you specify protocol "58" (ICMPv6) and specify - // an IPv4 CIDR block, traffic for all ICMP types and codes allowed, regardless - // of any that you specify. If you specify protocol "58" (ICMPv6) and specify - // an IPv6 CIDR block, you must specify an ICMP type and code. + // The IP protocol. You can specify all or -1 to mean all protocols. If you + // specify all, -1, or a protocol number other than tcp, udp, or icmp, traffic + // on all ports is allowed, regardless of any ports or ICMP types or codes you + // that specify. If you specify protocol 58 (ICMPv6) and specify an IPv4 CIDR + // block, traffic for all ICMP types and codes allowed, regardless of any that + // you specify. If you specify protocol 58 (ICMPv6) and specify an IPv6 CIDR + // block, you must specify an ICMP type and code. // // Protocol is a required field Protocol *string `locationName:"protocol" type:"string" required:"true"` @@ -79498,6 +59427,7 @@ func (s ReplaceNetworkAclEntryOutput) GoString() string { return s.String() } +// Contains the parameters for ReplaceRoute. type ReplaceRouteInput struct { _ struct{} `type:"structure"` @@ -79535,9 +59465,6 @@ type ReplaceRouteInput struct { // RouteTableId is a required field RouteTableId *string `locationName:"routeTableId" type:"string" required:"true"` - // The ID of a transit gateway. - TransitGatewayId *string `type:"string"` - // The ID of a VPC peering connection. VpcPeeringConnectionId *string `locationName:"vpcPeeringConnectionId" type:"string"` } @@ -79619,12 +59546,6 @@ func (s *ReplaceRouteInput) SetRouteTableId(v string) *ReplaceRouteInput { return s } -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *ReplaceRouteInput) SetTransitGatewayId(v string) *ReplaceRouteInput { - s.TransitGatewayId = &v - return s -} - // SetVpcPeeringConnectionId sets the VpcPeeringConnectionId field's value. func (s *ReplaceRouteInput) SetVpcPeeringConnectionId(v string) *ReplaceRouteInput { s.VpcPeeringConnectionId = &v @@ -79645,6 +59566,7 @@ func (s ReplaceRouteOutput) GoString() string { return s.String() } +// Contains the parameters for ReplaceRouteTableAssociation. type ReplaceRouteTableAssociationInput struct { _ struct{} `type:"structure"` @@ -79709,6 +59631,7 @@ func (s *ReplaceRouteTableAssociationInput) SetRouteTableId(v string) *ReplaceRo return s } +// Contains the output of ReplaceRouteTableAssociation. type ReplaceRouteTableAssociationOutput struct { _ struct{} `type:"structure"` @@ -79732,112 +59655,7 @@ func (s *ReplaceRouteTableAssociationOutput) SetNewAssociationId(v string) *Repl return s } -type ReplaceTransitGatewayRouteInput struct { - _ struct{} `type:"structure"` - - // Indicates whether traffic matching this route is to be dropped. - Blackhole *bool `type:"boolean"` - - // The CIDR range used for the destination match. Routing decisions are based - // on the most specific match. - // - // DestinationCidrBlock is a required field - DestinationCidrBlock *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `type:"string"` - - // The ID of the route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s ReplaceTransitGatewayRouteInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ReplaceTransitGatewayRouteInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *ReplaceTransitGatewayRouteInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ReplaceTransitGatewayRouteInput"} - if s.DestinationCidrBlock == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationCidrBlock")) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetBlackhole sets the Blackhole field's value. -func (s *ReplaceTransitGatewayRouteInput) SetBlackhole(v bool) *ReplaceTransitGatewayRouteInput { - s.Blackhole = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *ReplaceTransitGatewayRouteInput) SetDestinationCidrBlock(v string) *ReplaceTransitGatewayRouteInput { - s.DestinationCidrBlock = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *ReplaceTransitGatewayRouteInput) SetDryRun(v bool) *ReplaceTransitGatewayRouteInput { - s.DryRun = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *ReplaceTransitGatewayRouteInput) SetTransitGatewayAttachmentId(v string) *ReplaceTransitGatewayRouteInput { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *ReplaceTransitGatewayRouteInput) SetTransitGatewayRouteTableId(v string) *ReplaceTransitGatewayRouteInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type ReplaceTransitGatewayRouteOutput struct { - _ struct{} `type:"structure"` - - // Information about the modified route. - Route *TransitGatewayRoute `locationName:"route" type:"structure"` -} - -// String returns the string representation -func (s ReplaceTransitGatewayRouteOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ReplaceTransitGatewayRouteOutput) GoString() string { - return s.String() -} - -// SetRoute sets the Route field's value. -func (s *ReplaceTransitGatewayRouteOutput) SetRoute(v *TransitGatewayRoute) *ReplaceTransitGatewayRouteOutput { - s.Route = v - return s -} - +// Contains the parameters for ReportInstanceStatus. type ReportInstanceStatusInput struct { _ struct{} `type:"structure"` @@ -79853,12 +59671,12 @@ type ReportInstanceStatusInput struct { // The time at which the reported instance health state ended. EndTime *time.Time `locationName:"endTime" type:"timestamp"` - // The instances. + // One or more instances. // // Instances is a required field Instances []*string `locationName:"instanceId" locationNameList:"InstanceId" type:"list" required:"true"` - // The reason codes that describe the health state of your instance. + // One or more reason codes that describe the health state of your instance. // // * instance-stuck-in-state: My instance is stuck in a state. // @@ -79991,26 +59809,16 @@ type RequestLaunchTemplateData struct { // cannot be changed using this action. BlockDeviceMappings []*LaunchTemplateBlockDeviceMappingRequest `locationName:"BlockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"` - // The Capacity Reservation targeting option. If you do not specify this parameter, - // the instance's Capacity Reservation preference defaults to open, which enables - // it to run in any open Capacity Reservation that has matching attributes (instance - // type, platform, Availability Zone). - CapacityReservationSpecification *LaunchTemplateCapacityReservationSpecificationRequest `type:"structure"` - // The CPU options for the instance. For more information, see Optimizing CPU - // Options (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) + // Options (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) // in the Amazon Elastic Compute Cloud User Guide. CpuOptions *LaunchTemplateCpuOptionsRequest `type:"structure"` - // The credit option for CPU usage of the instance. Valid for T2 or T3 instances - // only. + // The credit option for CPU usage of the instance. Valid for T2 instances only. CreditSpecification *CreditSpecificationRequest `type:"structure"` - // If you set this parameter to true, you can't terminate the instance using - // the Amazon EC2 console, CLI, or API; otherwise, you can. To change this attribute - // after launch, use ModifyInstanceAttribute (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html). - // Alternatively, if you set InstanceInitiatedShutdownBehavior to terminate, - // you can terminate the instance by running the shutdown command from the instance. + // If set to true, you can't terminate the instance using the Amazon EC2 console, + // CLI, or API. To change this attribute to false after launch, use ModifyInstanceAttribute. DisableApiTermination *bool `type:"boolean"` // Indicates whether the instance is optimized for Amazon EBS I/O. This optimization @@ -80023,20 +59831,10 @@ type RequestLaunchTemplateData struct { // An elastic GPU to associate with the instance. ElasticGpuSpecifications []*ElasticGpuSpecification `locationName:"ElasticGpuSpecification" locationNameList:"ElasticGpuSpecification" type:"list"` - // The elastic inference accelerator for the instance. - ElasticInferenceAccelerators []*LaunchTemplateElasticInferenceAccelerator `locationName:"ElasticInferenceAccelerator" locationNameList:"item" type:"list"` - - // Indicates whether an instance is enabled for hibernation. This parameter - // is valid only if the instance meets the hibernation prerequisites (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html#hibernating-prerequisites). - // Hibernation is currently supported only for Amazon Linux. For more information, - // see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) - // in the Amazon Elastic Compute Cloud User Guide. - HibernationOptions *LaunchTemplateHibernationOptionsRequest `type:"structure"` - // The IAM instance profile. IamInstanceProfile *LaunchTemplateIamInstanceProfileSpecificationRequest `type:"structure"` - // The ID of the AMI. + // The ID of the AMI, which you can get by using DescribeImages. ImageId *string `type:"string"` // Indicates whether an instance stops or terminates when you initiate shutdown @@ -80048,32 +59846,28 @@ type RequestLaunchTemplateData struct { // The market (purchasing) option for the instances. InstanceMarketOptions *LaunchTemplateInstanceMarketOptionsRequest `type:"structure"` - // The instance type. For more information, see Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) + // The instance type. For more information, see Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) // in the Amazon Elastic Compute Cloud User Guide. InstanceType *string `type:"string" enum:"InstanceType"` // The ID of the kernel. // // We recommend that you use PV-GRUB instead of kernels and RAM disks. For more - // information, see User Provided Kernels (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) + // information, see User Provided Kernels (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) // in the Amazon Elastic Compute Cloud User Guide. KernelId *string `type:"string"` - // The name of the key pair. You can create a key pair using CreateKeyPair (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html) - // or ImportKeyPair (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html). + // The name of the key pair. You can create a key pair using CreateKeyPair or + // ImportKeyPair. // // If you do not specify a key pair, you can't connect to the instance unless // you choose an AMI that is configured to allow users another way to log in. KeyName *string `type:"string"` - // The license configurations. - LicenseSpecifications []*LaunchTemplateLicenseConfigurationRequest `locationName:"LicenseSpecification" locationNameList:"item" type:"list"` - // The monitoring for the instance. Monitoring *LaunchTemplatesMonitoringRequest `type:"structure"` - // One or more network interfaces. If you specify a network interface, you must - // specify any security groups and subnets as part of the network interface. + // One or more network interfaces. NetworkInterfaces []*LaunchTemplateInstanceNetworkInterfaceSpecificationRequest `locationName:"NetworkInterface" locationNameList:"InstanceNetworkInterfaceSpecification" type:"list"` // The placement for the instance. @@ -80082,12 +59876,11 @@ type RequestLaunchTemplateData struct { // The ID of the RAM disk. // // We recommend that you use PV-GRUB instead of kernels and RAM disks. For more - // information, see User Provided Kernels (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) + // information, see User Provided Kernels (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) // in the Amazon Elastic Compute Cloud User Guide. RamDiskId *string `type:"string"` - // One or more security group IDs. You can create a security group using CreateSecurityGroup - // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateSecurityGroup.html). + // One or more security group IDs. You can create a security group using CreateSecurityGroup. // You cannot specify both a security group ID and security name in the same // request. SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` @@ -80100,12 +59893,12 @@ type RequestLaunchTemplateData struct { // The tags to apply to the resources during launch. You can only tag instances // and volumes on launch. The specified tags are applied to all instances or // volumes that are created during launch. To tag a resource after it has been - // created, see CreateTags (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html). + // created, see CreateTags. TagSpecifications []*LaunchTemplateTagSpecificationRequest `locationName:"TagSpecification" locationNameList:"LaunchTemplateTagSpecificationRequest" type:"list"` // The Base64-encoded user data to make available to the instance. For more - // information, see Running Commands on Your Linux Instance at Launch (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) - // (Linux) and Adding User Data (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2-instance-metadata.html#instancedata-add-user-data) + // information, see Running Commands on Your Linux Instance at Launch (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) + // (Linux) and Adding User Data (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2-instance-metadata.html#instancedata-add-user-data) // (Windows). UserData *string `type:"string"` } @@ -80138,16 +59931,6 @@ func (s *RequestLaunchTemplateData) Validate() error { } } } - if s.ElasticInferenceAccelerators != nil { - for i, v := range s.ElasticInferenceAccelerators { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ElasticInferenceAccelerators", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -80161,12 +59944,6 @@ func (s *RequestLaunchTemplateData) SetBlockDeviceMappings(v []*LaunchTemplateBl return s } -// SetCapacityReservationSpecification sets the CapacityReservationSpecification field's value. -func (s *RequestLaunchTemplateData) SetCapacityReservationSpecification(v *LaunchTemplateCapacityReservationSpecificationRequest) *RequestLaunchTemplateData { - s.CapacityReservationSpecification = v - return s -} - // SetCpuOptions sets the CpuOptions field's value. func (s *RequestLaunchTemplateData) SetCpuOptions(v *LaunchTemplateCpuOptionsRequest) *RequestLaunchTemplateData { s.CpuOptions = v @@ -80197,18 +59974,6 @@ func (s *RequestLaunchTemplateData) SetElasticGpuSpecifications(v []*ElasticGpuS return s } -// SetElasticInferenceAccelerators sets the ElasticInferenceAccelerators field's value. -func (s *RequestLaunchTemplateData) SetElasticInferenceAccelerators(v []*LaunchTemplateElasticInferenceAccelerator) *RequestLaunchTemplateData { - s.ElasticInferenceAccelerators = v - return s -} - -// SetHibernationOptions sets the HibernationOptions field's value. -func (s *RequestLaunchTemplateData) SetHibernationOptions(v *LaunchTemplateHibernationOptionsRequest) *RequestLaunchTemplateData { - s.HibernationOptions = v - return s -} - // SetIamInstanceProfile sets the IamInstanceProfile field's value. func (s *RequestLaunchTemplateData) SetIamInstanceProfile(v *LaunchTemplateIamInstanceProfileSpecificationRequest) *RequestLaunchTemplateData { s.IamInstanceProfile = v @@ -80251,12 +60016,6 @@ func (s *RequestLaunchTemplateData) SetKeyName(v string) *RequestLaunchTemplateD return s } -// SetLicenseSpecifications sets the LicenseSpecifications field's value. -func (s *RequestLaunchTemplateData) SetLicenseSpecifications(v []*LaunchTemplateLicenseConfigurationRequest) *RequestLaunchTemplateData { - s.LicenseSpecifications = v - return s -} - // SetMonitoring sets the Monitoring field's value. func (s *RequestLaunchTemplateData) SetMonitoring(v *LaunchTemplatesMonitoringRequest) *RequestLaunchTemplateData { s.Monitoring = v @@ -80366,7 +60125,9 @@ type RequestSpotFleetOutput struct { _ struct{} `type:"structure"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` } // String returns the string representation @@ -80424,7 +60185,7 @@ type RequestSpotInstancesInput struct { BlockDurationMinutes *int64 `locationName:"blockDurationMinutes" type:"integer"` // Unique, case-sensitive identifier that you provide to ensure the idempotency - // of the request. For more information, see How to Ensure Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) + // of the request. For more information, see How to Ensure Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html) // in the Amazon EC2 User Guide for Linux Instances. ClientToken *string `locationName:"clientToken" type:"string"` @@ -80659,8 +60420,7 @@ type RequestSpotLaunchSpecification struct { // The ID of the subnet in which to launch the instance. SubnetId *string `locationName:"subnetId" type:"string"` - // The Base64-encoded user data for the instance. User data is limited to 16 - // KB. + // The Base64-encoded user data for the instance. UserData *string `locationName:"userData" type:"string"` } @@ -80789,10 +60549,10 @@ func (s *RequestSpotLaunchSpecification) SetUserData(v string) *RequestSpotLaunc type Reservation struct { _ struct{} `type:"structure"` - // [EC2-Classic only] The security groups. + // [EC2-Classic only] One or more security groups. Groups []*GroupIdentifier `locationName:"groupSet" locationNameList:"item" type:"list"` - // The instances. + // One or more instances. Instances []*Instance `locationName:"instancesSet" locationNameList:"item" type:"list"` // The ID of the AWS account that owns the reservation. @@ -81143,8 +60903,6 @@ type ReservedInstancesConfiguration struct { AvailabilityZone *string `locationName:"availabilityZone" type:"string"` // The number of modified Reserved Instances. - // - // This is a required field for a request. InstanceCount *int64 `locationName:"instanceCount" type:"integer"` // The instance type for the modified Reserved Instances. @@ -81154,7 +60912,7 @@ type ReservedInstancesConfiguration struct { // EC2-Classic or EC2-VPC. Platform *string `locationName:"platform" type:"string"` - // Whether the Reserved Instance is applied to instances in a Region or instances + // Whether the Reserved Instance is applied to instances in a region or instances // in a specific Availability Zone. Scope *string `locationName:"scope" type:"string" enum:"scope"` } @@ -81228,7 +60986,7 @@ type ReservedInstancesListing struct { _ struct{} `type:"structure"` // A unique, case-sensitive key supplied by the client to ensure that the request - // is idempotent. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // is idempotent. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `locationName:"clientToken" type:"string"` // The time the listing was created. @@ -81335,7 +61093,7 @@ type ReservedInstancesModification struct { _ struct{} `type:"structure"` // A unique, case-sensitive key supplied by the client to ensure that the request - // is idempotent. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // is idempotent. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `locationName:"clientToken" type:"string"` // The time when the modification request was created. @@ -81513,7 +61271,7 @@ type ReservedInstancesOffering struct { // GetReservedInstancesExchangeQuote to confirm that an exchange can be made. ReservedInstancesOfferingId *string `locationName:"reservedInstancesOfferingId" type:"string"` - // Whether the Reserved Instance is applied to instances in a Region or an Availability + // Whether the Reserved Instance is applied to instances in a region or an Availability // Zone. Scope *string `locationName:"scope" type:"string" enum:"scope"` @@ -81621,55 +61379,6 @@ func (s *ReservedInstancesOffering) SetUsagePrice(v float64) *ReservedInstancesO return s } -type ResetEbsDefaultKmsKeyIdInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s ResetEbsDefaultKmsKeyIdInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ResetEbsDefaultKmsKeyIdInput) GoString() string { - return s.String() -} - -// SetDryRun sets the DryRun field's value. -func (s *ResetEbsDefaultKmsKeyIdInput) SetDryRun(v bool) *ResetEbsDefaultKmsKeyIdInput { - s.DryRun = &v - return s -} - -type ResetEbsDefaultKmsKeyIdOutput struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the default CMK for EBS encryption by default. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` -} - -// String returns the string representation -func (s ResetEbsDefaultKmsKeyIdOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s ResetEbsDefaultKmsKeyIdOutput) GoString() string { - return s.String() -} - -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *ResetEbsDefaultKmsKeyIdOutput) SetKmsKeyId(v string) *ResetEbsDefaultKmsKeyIdOutput { - s.KmsKeyId = &v - return s -} - type ResetFpgaImageAttributeInput struct { _ struct{} `type:"structure"` @@ -81832,6 +61541,7 @@ func (s ResetImageAttributeOutput) GoString() string { return s.String() } +// Contains the parameters for ResetInstanceAttribute. type ResetInstanceAttributeInput struct { _ struct{} `type:"structure"` @@ -82108,11 +61818,8 @@ type ResponseLaunchTemplateData struct { // The block device mappings. BlockDeviceMappings []*LaunchTemplateBlockDeviceMapping `locationName:"blockDeviceMappingSet" locationNameList:"item" type:"list"` - // Information about the Capacity Reservation targeting option. - CapacityReservationSpecification *LaunchTemplateCapacityReservationSpecificationResponse `locationName:"capacityReservationSpecification" type:"structure"` - // The CPU options for the instance. For more information, see Optimizing CPU - // Options (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) + // Options (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) // in the Amazon Elastic Compute Cloud User Guide. CpuOptions *LaunchTemplateCpuOptions `locationName:"cpuOptions" type:"structure"` @@ -82129,14 +61836,6 @@ type ResponseLaunchTemplateData struct { // The elastic GPU specification. ElasticGpuSpecifications []*ElasticGpuSpecificationResponse `locationName:"elasticGpuSpecificationSet" locationNameList:"item" type:"list"` - // The elastic inference accelerator for the instance. - ElasticInferenceAccelerators []*LaunchTemplateElasticInferenceAcceleratorResponse `locationName:"elasticInferenceAcceleratorSet" locationNameList:"item" type:"list"` - - // Indicates whether an instance is configured for hibernation. For more information, - // see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) - // in the Amazon Elastic Compute Cloud User Guide. - HibernationOptions *LaunchTemplateHibernationOptions `locationName:"hibernationOptions" type:"structure"` - // The IAM instance profile. IamInstanceProfile *LaunchTemplateIamInstanceProfileSpecification `locationName:"iamInstanceProfile" type:"structure"` @@ -82159,9 +61858,6 @@ type ResponseLaunchTemplateData struct { // The name of the key pair. KeyName *string `locationName:"keyName" type:"string"` - // The license configurations. - LicenseSpecifications []*LaunchTemplateLicenseConfiguration `locationName:"licenseSet" locationNameList:"item" type:"list"` - // The monitoring for the instance. Monitoring *LaunchTemplatesMonitoring `locationName:"monitoring" type:"structure"` @@ -82203,12 +61899,6 @@ func (s *ResponseLaunchTemplateData) SetBlockDeviceMappings(v []*LaunchTemplateB return s } -// SetCapacityReservationSpecification sets the CapacityReservationSpecification field's value. -func (s *ResponseLaunchTemplateData) SetCapacityReservationSpecification(v *LaunchTemplateCapacityReservationSpecificationResponse) *ResponseLaunchTemplateData { - s.CapacityReservationSpecification = v - return s -} - // SetCpuOptions sets the CpuOptions field's value. func (s *ResponseLaunchTemplateData) SetCpuOptions(v *LaunchTemplateCpuOptions) *ResponseLaunchTemplateData { s.CpuOptions = v @@ -82239,18 +61929,6 @@ func (s *ResponseLaunchTemplateData) SetElasticGpuSpecifications(v []*ElasticGpu return s } -// SetElasticInferenceAccelerators sets the ElasticInferenceAccelerators field's value. -func (s *ResponseLaunchTemplateData) SetElasticInferenceAccelerators(v []*LaunchTemplateElasticInferenceAcceleratorResponse) *ResponseLaunchTemplateData { - s.ElasticInferenceAccelerators = v - return s -} - -// SetHibernationOptions sets the HibernationOptions field's value. -func (s *ResponseLaunchTemplateData) SetHibernationOptions(v *LaunchTemplateHibernationOptions) *ResponseLaunchTemplateData { - s.HibernationOptions = v - return s -} - // SetIamInstanceProfile sets the IamInstanceProfile field's value. func (s *ResponseLaunchTemplateData) SetIamInstanceProfile(v *LaunchTemplateIamInstanceProfileSpecification) *ResponseLaunchTemplateData { s.IamInstanceProfile = v @@ -82293,12 +61971,6 @@ func (s *ResponseLaunchTemplateData) SetKeyName(v string) *ResponseLaunchTemplat return s } -// SetLicenseSpecifications sets the LicenseSpecifications field's value. -func (s *ResponseLaunchTemplateData) SetLicenseSpecifications(v []*LaunchTemplateLicenseConfiguration) *ResponseLaunchTemplateData { - s.LicenseSpecifications = v - return s -} - // SetMonitoring sets the Monitoring field's value. func (s *ResponseLaunchTemplateData) SetMonitoring(v *LaunchTemplatesMonitoring) *ResponseLaunchTemplateData { s.Monitoring = v @@ -82347,6 +62019,7 @@ func (s *ResponseLaunchTemplateData) SetUserData(v string) *ResponseLaunchTempla return s } +// Contains the parameters for RestoreAddressToClassic. type RestoreAddressToClassicInput struct { _ struct{} `type:"structure"` @@ -82397,6 +62070,7 @@ func (s *RestoreAddressToClassicInput) SetPublicIp(v string) *RestoreAddressToCl return s } +// Contains the output of RestoreAddressToClassic. type RestoreAddressToClassicOutput struct { _ struct{} `type:"structure"` @@ -82429,112 +62103,7 @@ func (s *RestoreAddressToClassicOutput) SetStatus(v string) *RestoreAddressToCla return s } -type RevokeClientVpnIngressInput struct { - _ struct{} `type:"structure"` - - // The ID of the Active Directory group for which to revoke access. - AccessGroupId *string `type:"string"` - - // The ID of the Client VPN endpoint with which the authorization rule is associated. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // Indicates whether access should be revoked for all clients. - RevokeAllGroups *bool `type:"boolean"` - - // The IPv4 address range, in CIDR notation, of the network for which access - // is being removed. - // - // TargetNetworkCidr is a required field - TargetNetworkCidr *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s RevokeClientVpnIngressInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RevokeClientVpnIngressInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *RevokeClientVpnIngressInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "RevokeClientVpnIngressInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - if s.TargetNetworkCidr == nil { - invalidParams.Add(request.NewErrParamRequired("TargetNetworkCidr")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetAccessGroupId sets the AccessGroupId field's value. -func (s *RevokeClientVpnIngressInput) SetAccessGroupId(v string) *RevokeClientVpnIngressInput { - s.AccessGroupId = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *RevokeClientVpnIngressInput) SetClientVpnEndpointId(v string) *RevokeClientVpnIngressInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *RevokeClientVpnIngressInput) SetDryRun(v bool) *RevokeClientVpnIngressInput { - s.DryRun = &v - return s -} - -// SetRevokeAllGroups sets the RevokeAllGroups field's value. -func (s *RevokeClientVpnIngressInput) SetRevokeAllGroups(v bool) *RevokeClientVpnIngressInput { - s.RevokeAllGroups = &v - return s -} - -// SetTargetNetworkCidr sets the TargetNetworkCidr field's value. -func (s *RevokeClientVpnIngressInput) SetTargetNetworkCidr(v string) *RevokeClientVpnIngressInput { - s.TargetNetworkCidr = &v - return s -} - -type RevokeClientVpnIngressOutput struct { - _ struct{} `type:"structure"` - - // The current state of the authorization rule. - Status *ClientVpnAuthorizationRuleStatus `locationName:"status" type:"structure"` -} - -// String returns the string representation -func (s RevokeClientVpnIngressOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s RevokeClientVpnIngressOutput) GoString() string { - return s.String() -} - -// SetStatus sets the Status field's value. -func (s *RevokeClientVpnIngressOutput) SetStatus(v *ClientVpnAuthorizationRuleStatus) *RevokeClientVpnIngressOutput { - s.Status = v - return s -} - +// Contains the parameters for RevokeSecurityGroupEgress. type RevokeSecurityGroupEgressInput struct { _ struct{} `type:"structure"` @@ -82555,8 +62124,8 @@ type RevokeSecurityGroupEgressInput struct { // GroupId is a required field GroupId *string `locationName:"groupId" type:"string" required:"true"` - // The sets of IP permissions. You can't specify a destination security group - // and a CIDR IP address range in the same set of permissions. + // One or more sets of IP permissions. You can't specify a destination security + // group and a CIDR IP address range in the same set of permissions. IpPermissions []*IpPermission `locationName:"ipPermissions" locationNameList:"item" type:"list"` // Not supported. Use a set of IP permissions to specify the protocol name or @@ -82666,6 +62235,7 @@ func (s RevokeSecurityGroupEgressOutput) GoString() string { return s.String() } +// Contains the parameters for RevokeSecurityGroupIngress. type RevokeSecurityGroupIngressInput struct { _ struct{} `type:"structure"` @@ -82692,8 +62262,8 @@ type RevokeSecurityGroupIngressInput struct { // either the security group ID or the security group name in the request. GroupName *string `type:"string"` - // The sets of IP permissions. You can't specify a source security group and - // a CIDR IP address range in the same set of permissions. + // One or more sets of IP permissions. You can't specify a source security group + // and a CIDR IP address range in the same set of permissions. IpPermissions []*IpPermission `locationNameList:"item" type:"list"` // The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml)). @@ -82851,10 +62421,7 @@ type Route struct { // VPC, or the specified NAT instance has been terminated). State *string `locationName:"state" type:"string" enum:"RouteState"` - // The ID of a transit gateway. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` - - // The ID of a VPC peering connection. + // The ID of the VPC peering connection. VpcPeeringConnectionId *string `locationName:"vpcPeeringConnectionId" type:"string"` } @@ -82934,12 +62501,6 @@ func (s *Route) SetState(v string) *Route { return s } -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *Route) SetTransitGatewayId(v string) *Route { - s.TransitGatewayId = &v - return s -} - // SetVpcPeeringConnectionId sets the VpcPeeringConnectionId field's value. func (s *Route) SetVpcPeeringConnectionId(v string) *Route { s.VpcPeeringConnectionId = &v @@ -82953,9 +62514,6 @@ type RouteTable struct { // The associations between the route table and one or more subnets. Associations []*RouteTableAssociation `locationName:"associationSet" locationNameList:"item" type:"list"` - // The ID of the AWS account that owns the route table. - OwnerId *string `locationName:"ownerId" type:"string"` - // Any virtual private gateway (VGW) propagating routes. PropagatingVgws []*PropagatingVgw `locationName:"propagatingVgwSet" locationNameList:"item" type:"list"` @@ -82988,12 +62546,6 @@ func (s *RouteTable) SetAssociations(v []*RouteTableAssociation) *RouteTable { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *RouteTable) SetOwnerId(v string) *RouteTable { - s.OwnerId = &v - return s -} - // SetPropagatingVgws sets the PropagatingVgws field's value. func (s *RouteTable) SetPropagatingVgws(v []*PropagatingVgw) *RouteTable { s.PropagatingVgws = v @@ -83075,46 +62627,43 @@ func (s *RouteTableAssociation) SetSubnetId(v string) *RouteTableAssociation { return s } +// Contains the parameters for RunInstances. type RunInstancesInput struct { _ struct{} `type:"structure"` // Reserved. AdditionalInfo *string `locationName:"additionalInfo" type:"string"` - // The block device mapping entries. + // One or more block device mapping entries. You can't specify both a snapshot + // ID and an encryption value. This is because only blank volumes can be encrypted + // on creation. If a snapshot is the basis for a volume, it is not blank and + // its encryption status is used for the volume encryption status. BlockDeviceMappings []*BlockDeviceMapping `locationName:"BlockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"` - // Information about the Capacity Reservation targeting option. If you do not - // specify this parameter, the instance's Capacity Reservation preference defaults - // to open, which enables it to run in any open Capacity Reservation that has - // matching attributes (instance type, platform, Availability Zone). - CapacityReservationSpecification *CapacityReservationSpecification `type:"structure"` - // Unique, case-sensitive identifier you provide to ensure the idempotency of - // the request. For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // the request. For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). // // Constraints: Maximum 64 ASCII characters ClientToken *string `locationName:"clientToken" type:"string"` // The CPU options for the instance. For more information, see Optimizing CPU - // Options (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) + // Options (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-optimize-cpu.html) // in the Amazon Elastic Compute Cloud User Guide. CpuOptions *CpuOptionsRequest `type:"structure"` - // The credit option for CPU usage of the T2 or T3 instance. Valid values are - // standard and unlimited. To change this attribute after launch, use ModifyInstanceCreditSpecification - // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceCreditSpecification.html). - // For more information, see Burstable Performance Instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/burstable-performance-instances.html) + // The credit option for CPU usage of the instance. Valid values are standard + // and unlimited. To change this attribute after launch, use ModifyInstanceCreditSpecification. + // For more information, see T2 Instances (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html) // in the Amazon Elastic Compute Cloud User Guide. // - // Default: standard (T2 instances) or unlimited (T3 instances) + // Default: standard CreditSpecification *CreditSpecificationRequest `type:"structure"` // If you set this parameter to true, you can't terminate the instance using // the Amazon EC2 console, CLI, or API; otherwise, you can. To change this attribute - // after launch, use ModifyInstanceAttribute (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyInstanceAttribute.html). - // Alternatively, if you set InstanceInitiatedShutdownBehavior to terminate, - // you can terminate the instance by running the shutdown command from the instance. + // to false after launch, use ModifyInstanceAttribute. Alternatively, if you + // set InstanceInitiatedShutdownBehavior to terminate, you can terminate the + // instance by running the shutdown command from the instance. // // Default: false DisableApiTermination *bool `locationName:"disableApiTermination" type:"boolean"` @@ -83134,27 +62683,15 @@ type RunInstancesInput struct { // Default: false EbsOptimized *bool `locationName:"ebsOptimized" type:"boolean"` - // An elastic GPU to associate with the instance. An Elastic GPU is a GPU resource - // that you can attach to your Windows instance to accelerate the graphics performance - // of your applications. For more information, see Amazon EC2 Elastic GPUs (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/elastic-graphics.html) - // in the Amazon Elastic Compute Cloud User Guide. + // An elastic GPU to associate with the instance. ElasticGpuSpecification []*ElasticGpuSpecification `locationNameList:"item" type:"list"` - // An elastic inference accelerator to associate with the instance. Elastic - // inference accelerators are a resource you can attach to your Amazon EC2 instances - // to accelerate your Deep Learning (DL) inference workloads. - ElasticInferenceAccelerators []*ElasticInferenceAccelerator `locationName:"ElasticInferenceAccelerator" locationNameList:"item" type:"list"` - - // Indicates whether an instance is enabled for hibernation. For more information, - // see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) - // in the Amazon Elastic Compute Cloud User Guide. - HibernationOptions *HibernationOptionsRequest `type:"structure"` - // The IAM instance profile. IamInstanceProfile *IamInstanceProfileSpecification `locationName:"iamInstanceProfile" type:"structure"` - // The ID of the AMI. An AMI ID is required to launch an instance and must be - // specified here or in a launch template. + // The ID of the AMI, which you can get by calling DescribeImages. An AMI is + // required to launch an instance and must be specified here or in a launch + // template. ImageId *string `type:"string"` // Indicates whether an instance stops or terminates when you initiate shutdown @@ -83169,40 +62706,35 @@ type RunInstancesInput struct { // InstanceInterruptionBehavior is set to either hibernate or stop. InstanceMarketOptions *InstanceMarketOptionsRequest `type:"structure"` - // The instance type. For more information, see Instance Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) + // The instance type. For more information, see Instance Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html) // in the Amazon Elastic Compute Cloud User Guide. // // Default: m1.small InstanceType *string `type:"string" enum:"InstanceType"` - // [EC2-VPC] The number of IPv6 addresses to associate with the primary network + // [EC2-VPC] A number of IPv6 addresses to associate with the primary network // interface. Amazon EC2 chooses the IPv6 addresses from the range of your subnet. // You cannot specify this option and the option to assign specific IPv6 addresses // in the same request. You can specify this option if you've specified a minimum // number of instances to launch. - // - // You cannot specify this option and the network interfaces option in the same - // request. Ipv6AddressCount *int64 `type:"integer"` - // [EC2-VPC] The IPv6 addresses from the range of the subnet to associate with - // the primary network interface. You cannot specify this option and the option - // to assign a number of IPv6 addresses in the same request. You cannot specify - // this option if you've specified a minimum number of instances to launch. - // - // You cannot specify this option and the network interfaces option in the same - // request. + // [EC2-VPC] Specify one or more IPv6 addresses from the range of the subnet + // to associate with the primary network interface. You cannot specify this + // option and the option to assign a number of IPv6 addresses in the same request. + // You cannot specify this option if you've specified a minimum number of instances + // to launch. Ipv6Addresses []*InstanceIpv6Address `locationName:"Ipv6Address" locationNameList:"item" type:"list"` // The ID of the kernel. // // We recommend that you use PV-GRUB instead of kernels and RAM disks. For more - // information, see PV-GRUB (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) + // information, see PV-GRUB (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) // in the Amazon Elastic Compute Cloud User Guide. KernelId *string `type:"string"` - // The name of the key pair. You can create a key pair using CreateKeyPair (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateKeyPair.html) - // or ImportKeyPair (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ImportKeyPair.html). + // The name of the key pair. You can create a key pair using CreateKeyPair or + // ImportKeyPair. // // If you do not specify a key pair, you can't connect to the instance unless // you choose an AMI that is configured to allow users another way to log in. @@ -83213,9 +62745,6 @@ type RunInstancesInput struct { // You can specify either the name or ID of a launch template, but not both. LaunchTemplate *LaunchTemplateSpecification `type:"structure"` - // The license configurations. - LicenseSpecifications []*LicenseConfigurationRequest `locationName:"LicenseSpecification" locationNameList:"item" type:"list"` - // The maximum number of instances to launch. If you specify more instances // than Amazon EC2 can launch in the target Availability Zone, Amazon EC2 launches // the largest possible number of instances above MinCount. @@ -83240,12 +62769,10 @@ type RunInstancesInput struct { // MinCount is a required field MinCount *int64 `type:"integer" required:"true"` - // Specifies whether detailed monitoring is enabled for the instance. + // The monitoring for the instance. Monitoring *RunInstancesMonitoringEnabled `type:"structure"` - // The network interfaces to associate with the instance. If you specify a network - // interface, you must specify any security groups and subnets as part of the - // network interface. + // One or more network interfaces. NetworkInterfaces []*InstanceNetworkInterfaceSpecification `locationName:"networkInterface" locationNameList:"item" type:"list"` // The placement for the instance. @@ -83258,55 +62785,41 @@ type RunInstancesInput struct { // this option if you've specified the option to designate a private IP address // as the primary IP address in a network interface specification. You cannot // specify this option if you're launching more than one instance in the request. - // - // You cannot specify this option and the network interfaces option in the same - // request. PrivateIpAddress *string `locationName:"privateIpAddress" type:"string"` - // The ID of the RAM disk to select. Some kernels require additional drivers - // at launch. Check the kernel requirements for information about whether you - // need to specify a RAM disk. To find kernel requirements, go to the AWS Resource - // Center and search for the kernel ID. + // The ID of the RAM disk. // // We recommend that you use PV-GRUB instead of kernels and RAM disks. For more - // information, see PV-GRUB (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) + // information, see PV-GRUB (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/UserProvidedkernels.html) // in the Amazon Elastic Compute Cloud User Guide. RamdiskId *string `type:"string"` - // The IDs of the security groups. You can create a security group using CreateSecurityGroup - // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateSecurityGroup.html). + // One or more security group IDs. You can create a security group using CreateSecurityGroup. // - // If you specify a network interface, you must specify any security groups - // as part of the network interface. + // Default: Amazon EC2 uses the default security group. SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` - // [EC2-Classic, default VPC] The names of the security groups. For a nondefault + // [EC2-Classic, default VPC] One or more security group names. For a nondefault // VPC, you must use security group IDs instead. // - // If you specify a network interface, you must specify any security groups - // as part of the network interface. - // // Default: Amazon EC2 uses the default security group. SecurityGroups []*string `locationName:"SecurityGroup" locationNameList:"SecurityGroup" type:"list"` // [EC2-VPC] The ID of the subnet to launch the instance into. - // - // If you specify a network interface, you must specify any subnets as part - // of the network interface. SubnetId *string `type:"string"` // The tags to apply to the resources during launch. You can only tag instances // and volumes on launch. The specified tags are applied to all instances or // volumes that are created during launch. To tag a resource after it has been - // created, see CreateTags (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateTags.html). + // created, see CreateTags. TagSpecifications []*TagSpecification `locationName:"TagSpecification" locationNameList:"item" type:"list"` // The user data to make available to the instance. For more information, see - // Running Commands on Your Linux Instance at Launch (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) - // (Linux) and Adding User Data (https://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2-instance-metadata.html#instancedata-add-user-data) + // Running Commands on Your Linux Instance at Launch (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html) + // (Linux) and Adding User Data (http://docs.aws.amazon.com/AWSEC2/latest/WindowsGuide/ec2-instance-metadata.html#instancedata-add-user-data) // (Windows). If you are using a command line tool, base64-encoding is performed // for you, and you can load the text from a file. Otherwise, you must provide - // base64-encoded text. User data is limited to 16 KB. + // base64-encoded text. UserData *string `type:"string"` } @@ -83344,16 +62857,6 @@ func (s *RunInstancesInput) Validate() error { } } } - if s.ElasticInferenceAccelerators != nil { - for i, v := range s.ElasticInferenceAccelerators { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ElasticInferenceAccelerators", i), err.(request.ErrInvalidParams)) - } - } - } if s.Monitoring != nil { if err := s.Monitoring.Validate(); err != nil { invalidParams.AddNested("Monitoring", err.(request.ErrInvalidParams)) @@ -83378,12 +62881,6 @@ func (s *RunInstancesInput) SetBlockDeviceMappings(v []*BlockDeviceMapping) *Run return s } -// SetCapacityReservationSpecification sets the CapacityReservationSpecification field's value. -func (s *RunInstancesInput) SetCapacityReservationSpecification(v *CapacityReservationSpecification) *RunInstancesInput { - s.CapacityReservationSpecification = v - return s -} - // SetClientToken sets the ClientToken field's value. func (s *RunInstancesInput) SetClientToken(v string) *RunInstancesInput { s.ClientToken = &v @@ -83426,18 +62923,6 @@ func (s *RunInstancesInput) SetElasticGpuSpecification(v []*ElasticGpuSpecificat return s } -// SetElasticInferenceAccelerators sets the ElasticInferenceAccelerators field's value. -func (s *RunInstancesInput) SetElasticInferenceAccelerators(v []*ElasticInferenceAccelerator) *RunInstancesInput { - s.ElasticInferenceAccelerators = v - return s -} - -// SetHibernationOptions sets the HibernationOptions field's value. -func (s *RunInstancesInput) SetHibernationOptions(v *HibernationOptionsRequest) *RunInstancesInput { - s.HibernationOptions = v - return s -} - // SetIamInstanceProfile sets the IamInstanceProfile field's value. func (s *RunInstancesInput) SetIamInstanceProfile(v *IamInstanceProfileSpecification) *RunInstancesInput { s.IamInstanceProfile = v @@ -83498,12 +62983,6 @@ func (s *RunInstancesInput) SetLaunchTemplate(v *LaunchTemplateSpecification) *R return s } -// SetLicenseSpecifications sets the LicenseSpecifications field's value. -func (s *RunInstancesInput) SetLicenseSpecifications(v []*LicenseConfigurationRequest) *RunInstancesInput { - s.LicenseSpecifications = v - return s -} - // SetMaxCount sets the MaxCount field's value. func (s *RunInstancesInput) SetMaxCount(v int64) *RunInstancesInput { s.MaxCount = &v @@ -83621,7 +63100,7 @@ type RunScheduledInstancesInput struct { _ struct{} `type:"structure"` // Unique, case-sensitive identifier that ensures the idempotency of the request. - // For more information, see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // For more information, see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `type:"string" idempotencyToken:"true"` // Checks whether you have the required permissions for the action, without @@ -83739,7 +63218,7 @@ type S3Storage struct { // The access key ID of the owner of the bucket. Before you specify a value // for your access key ID, review and follow the guidance in Best Practices - // for Managing AWS Access Keys (https://docs.aws.amazon.com/general/latest/gr/aws-access-keys-best-practices.html). + // for Managing AWS Access Keys (http://docs.aws.amazon.com/general/latest/gr/aws-access-keys-best-practices.html). AWSAccessKeyId *string `type:"string"` // The bucket in which to store the AMI. You can specify a bucket that you already @@ -84292,7 +63771,7 @@ type ScheduledInstancesEbs struct { // for the volume. For gp2 volumes, this represents the baseline performance // of the volume and the rate at which the volume accumulates I/O credits for // bursting. For more information about gp2 baseline performance, I/O credits, - // and bursting, see Amazon EBS Volume Types (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) + // and bursting, see Amazon EBS Volume Types (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) // in the Amazon Elastic Compute Cloud User Guide. // // Constraint: Range is 100-20000 IOPS for io1 volumes and 100-10000 IOPS for @@ -84429,7 +63908,7 @@ func (s *ScheduledInstancesIpv6Address) SetIpv6Address(v string) *ScheduledInsta type ScheduledInstancesLaunchSpecification struct { _ struct{} `type:"structure"` - // The block device mapping entries. + // One or more block device mapping entries. BlockDeviceMappings []*ScheduledInstancesBlockDeviceMapping `locationName:"BlockDeviceMapping" locationNameList:"BlockDeviceMapping" type:"list"` // Indicates whether the instances are optimized for EBS I/O. This optimization @@ -84461,7 +63940,7 @@ type ScheduledInstancesLaunchSpecification struct { // Enable or disable monitoring for the instances. Monitoring *ScheduledInstancesMonitoring `type:"structure"` - // The network interfaces. + // One or more network interfaces. NetworkInterfaces []*ScheduledInstancesNetworkInterface `locationName:"NetworkInterface" locationNameList:"NetworkInterface" type:"list"` // The placement information. @@ -84470,7 +63949,7 @@ type ScheduledInstancesLaunchSpecification struct { // The ID of the RAM disk. RamdiskId *string `type:"string"` - // The IDs of the security groups. + // The IDs of one or more security groups. SecurityGroupIds []*string `locationName:"SecurityGroupId" locationNameList:"SecurityGroupId" type:"list"` // The ID of the subnet in which to launch the instances. @@ -84631,14 +64110,14 @@ type ScheduledInstancesNetworkInterface struct { // The index of the device for the network interface attachment. DeviceIndex *int64 `type:"integer"` - // The IDs of the security groups. + // The IDs of one or more security groups. Groups []*string `locationName:"Group" locationNameList:"SecurityGroupId" type:"list"` // The number of IPv6 addresses to assign to the network interface. The IPv6 // addresses are automatically selected from the subnet range. Ipv6AddressCount *int64 `type:"integer"` - // The specific IPv6 addresses from the subnet range. + // One or more specific IPv6 addresses from the subnet range. Ipv6Addresses []*ScheduledInstancesIpv6Address `locationName:"Ipv6Address" locationNameList:"Ipv6Address" type:"list"` // The ID of the network interface. @@ -84806,138 +64285,6 @@ func (s *ScheduledInstancesPrivateIpAddressConfig) SetPrivateIpAddress(v string) return s } -type SearchTransitGatewayRoutesInput struct { - _ struct{} `type:"structure"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // One or more filters. The possible values are: - // - // * attachment.transit-gateway-attachment-id- The id of the transit gateway - // attachment. - // - // * attachment.resource-id - The resource id of the transit gateway attachment. - // - // * attachment.resource-type - The attachment resource type (vpc | vpn). - // - // * route-search.exact-match - The exact match of the specified filter. - // - // * route-search.longest-prefix-match - The longest prefix that matches - // the route. - // - // * route-search.subnet-of-match - The routes with a subnet that match the - // specified CIDR filter. - // - // * route-search.supernet-of-match - The routes with a CIDR that encompass - // the CIDR filter. For example, if you have 10.0.1.0/29 and 10.0.1.0/31 - // routes in your route table and you specify supernet-of-match as 10.0.1.0/30, - // then the result returns 10.0.1.0/29. - // - // * state - The state of the route (active | blackhole). - // - // * type - The type of roue (propagated | static). - // - // Filters is a required field - Filters []*Filter `locationName:"Filter" locationNameList:"Filter" type:"list" required:"true"` - - // The maximum number of routes to return. - MaxResults *int64 `min:"5" type:"integer"` - - // The ID of the transit gateway route table. - // - // TransitGatewayRouteTableId is a required field - TransitGatewayRouteTableId *string `type:"string" required:"true"` -} - -// String returns the string representation -func (s SearchTransitGatewayRoutesInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s SearchTransitGatewayRoutesInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *SearchTransitGatewayRoutesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "SearchTransitGatewayRoutesInput"} - if s.Filters == nil { - invalidParams.Add(request.NewErrParamRequired("Filters")) - } - if s.MaxResults != nil && *s.MaxResults < 5 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 5)) - } - if s.TransitGatewayRouteTableId == nil { - invalidParams.Add(request.NewErrParamRequired("TransitGatewayRouteTableId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDryRun sets the DryRun field's value. -func (s *SearchTransitGatewayRoutesInput) SetDryRun(v bool) *SearchTransitGatewayRoutesInput { - s.DryRun = &v - return s -} - -// SetFilters sets the Filters field's value. -func (s *SearchTransitGatewayRoutesInput) SetFilters(v []*Filter) *SearchTransitGatewayRoutesInput { - s.Filters = v - return s -} - -// SetMaxResults sets the MaxResults field's value. -func (s *SearchTransitGatewayRoutesInput) SetMaxResults(v int64) *SearchTransitGatewayRoutesInput { - s.MaxResults = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *SearchTransitGatewayRoutesInput) SetTransitGatewayRouteTableId(v string) *SearchTransitGatewayRoutesInput { - s.TransitGatewayRouteTableId = &v - return s -} - -type SearchTransitGatewayRoutesOutput struct { - _ struct{} `type:"structure"` - - // Indicates whether there are additional routes available. - AdditionalRoutesAvailable *bool `locationName:"additionalRoutesAvailable" type:"boolean"` - - // Information about the routes. - Routes []*TransitGatewayRoute `locationName:"routeSet" locationNameList:"item" type:"list"` -} - -// String returns the string representation -func (s SearchTransitGatewayRoutesOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s SearchTransitGatewayRoutesOutput) GoString() string { - return s.String() -} - -// SetAdditionalRoutesAvailable sets the AdditionalRoutesAvailable field's value. -func (s *SearchTransitGatewayRoutesOutput) SetAdditionalRoutesAvailable(v bool) *SearchTransitGatewayRoutesOutput { - s.AdditionalRoutesAvailable = &v - return s -} - -// SetRoutes sets the Routes field's value. -func (s *SearchTransitGatewayRoutesOutput) SetRoutes(v []*TransitGatewayRoute) *SearchTransitGatewayRoutesOutput { - s.Routes = v - return s -} - // Describes a security group type SecurityGroup struct { _ struct{} `type:"structure"` @@ -84951,10 +64298,10 @@ type SecurityGroup struct { // The name of the security group. GroupName *string `locationName:"groupName" type:"string"` - // The inbound rules associated with the security group. + // One or more inbound rules associated with the security group. IpPermissions []*IpPermission `locationName:"ipPermissions" locationNameList:"item" type:"list"` - // [VPC only] The outbound rules associated with the security group. + // [EC2-VPC] One or more outbound rules associated with the security group. IpPermissionsEgress []*IpPermission `locationName:"ipPermissionsEgress" locationNameList:"item" type:"list"` // The AWS account ID of the owner of the security group. @@ -84963,7 +64310,7 @@ type SecurityGroup struct { // Any tags assigned to the security group. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - // [VPC only] The ID of the VPC for the security group. + // [EC2-VPC] The ID of the VPC for the security group. VpcId *string `locationName:"vpcId" type:"string"` } @@ -85063,10 +64410,14 @@ type SecurityGroupReference struct { _ struct{} `type:"structure"` // The ID of your security group. - GroupId *string `locationName:"groupId" type:"string"` + // + // GroupId is a required field + GroupId *string `locationName:"groupId" type:"string" required:"true"` // The ID of the VPC with the referencing security group. - ReferencingVpcId *string `locationName:"referencingVpcId" type:"string"` + // + // ReferencingVpcId is a required field + ReferencingVpcId *string `locationName:"referencingVpcId" type:"string" required:"true"` // The ID of the VPC peering connection. VpcPeeringConnectionId *string `locationName:"vpcPeeringConnectionId" type:"string"` @@ -85114,10 +64465,6 @@ type ServiceConfiguration struct { // The DNS names for the service. BaseEndpointDnsNames []*string `locationName:"baseEndpointDnsNameSet" locationNameList:"item" type:"list"` - // Indicates whether the service manages it's VPC endpoints. Management of the - // service VPC endpoints using the VPC endpoint API is restricted. - ManagesVpcEndpoints *bool `locationName:"managesVpcEndpoints" type:"boolean"` - // The Amazon Resource Names (ARNs) of the Network Load Balancers for the service. NetworkLoadBalancerArns []*string `locationName:"networkLoadBalancerArnSet" locationNameList:"item" type:"list"` @@ -85135,9 +64482,6 @@ type ServiceConfiguration struct { // The type of service. ServiceType []*ServiceTypeDetail `locationName:"serviceType" locationNameList:"item" type:"list"` - - // Any tags assigned to the service. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` } // String returns the string representation @@ -85168,12 +64512,6 @@ func (s *ServiceConfiguration) SetBaseEndpointDnsNames(v []*string) *ServiceConf return s } -// SetManagesVpcEndpoints sets the ManagesVpcEndpoints field's value. -func (s *ServiceConfiguration) SetManagesVpcEndpoints(v bool) *ServiceConfiguration { - s.ManagesVpcEndpoints = &v - return s -} - // SetNetworkLoadBalancerArns sets the NetworkLoadBalancerArns field's value. func (s *ServiceConfiguration) SetNetworkLoadBalancerArns(v []*string) *ServiceConfiguration { s.NetworkLoadBalancerArns = v @@ -85210,12 +64548,6 @@ func (s *ServiceConfiguration) SetServiceType(v []*ServiceTypeDetail) *ServiceCo return s } -// SetTags sets the Tags field's value. -func (s *ServiceConfiguration) SetTags(v []*Tag) *ServiceConfiguration { - s.Tags = v - return s -} - // Describes a VPC endpoint service. type ServiceDetail struct { _ struct{} `type:"structure"` @@ -85230,28 +64562,18 @@ type ServiceDetail struct { // The DNS names for the service. BaseEndpointDnsNames []*string `locationName:"baseEndpointDnsNameSet" locationNameList:"item" type:"list"` - // Indicates whether the service manages it's VPC endpoints. Management of the - // service VPC endpoints using the VPC endpoint API is restricted. - ManagesVpcEndpoints *bool `locationName:"managesVpcEndpoints" type:"boolean"` - // The AWS account ID of the service owner. Owner *string `locationName:"owner" type:"string"` // The private DNS name for the service. PrivateDnsName *string `locationName:"privateDnsName" type:"string"` - // The ID of the endpoint service. - ServiceId *string `locationName:"serviceId" type:"string"` - // The Amazon Resource Name (ARN) of the service. ServiceName *string `locationName:"serviceName" type:"string"` // The type of service. ServiceType []*ServiceTypeDetail `locationName:"serviceType" locationNameList:"item" type:"list"` - // Any tags assigned to the service. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - // Indicates whether the service supports endpoint policies. VpcEndpointPolicySupported *bool `locationName:"vpcEndpointPolicySupported" type:"boolean"` } @@ -85284,12 +64606,6 @@ func (s *ServiceDetail) SetBaseEndpointDnsNames(v []*string) *ServiceDetail { return s } -// SetManagesVpcEndpoints sets the ManagesVpcEndpoints field's value. -func (s *ServiceDetail) SetManagesVpcEndpoints(v bool) *ServiceDetail { - s.ManagesVpcEndpoints = &v - return s -} - // SetOwner sets the Owner field's value. func (s *ServiceDetail) SetOwner(v string) *ServiceDetail { s.Owner = &v @@ -85302,12 +64618,6 @@ func (s *ServiceDetail) SetPrivateDnsName(v string) *ServiceDetail { return s } -// SetServiceId sets the ServiceId field's value. -func (s *ServiceDetail) SetServiceId(v string) *ServiceDetail { - s.ServiceId = &v - return s -} - // SetServiceName sets the ServiceName field's value. func (s *ServiceDetail) SetServiceName(v string) *ServiceDetail { s.ServiceName = &v @@ -85320,12 +64630,6 @@ func (s *ServiceDetail) SetServiceType(v []*ServiceTypeDetail) *ServiceDetail { return s } -// SetTags sets the Tags field's value. -func (s *ServiceDetail) SetTags(v []*Tag) *ServiceDetail { - s.Tags = v - return s -} - // SetVpcEndpointPolicySupported sets the VpcEndpointPolicySupported field's value. func (s *ServiceDetail) SetVpcEndpointPolicySupported(v bool) *ServiceDetail { s.VpcEndpointPolicySupported = &v @@ -85454,7 +64758,7 @@ type Snapshot struct { // the original volume or snapshot copy. Because data encryption keys are inherited // by volumes created from snapshots, and vice versa, if snapshots share the // same data encryption key identifier, then they belong to the same volume/snapshot - // lineage. This parameter is only returned by DescribeSnapshots. + // lineage. This parameter is only returned by the DescribeSnapshots API operation. DataEncryptionKeyId *string `locationName:"dataEncryptionKeyId" type:"string"` // The description for the snapshot. @@ -85463,14 +64767,14 @@ type Snapshot struct { // Indicates whether the snapshot is encrypted. Encrypted *bool `locationName:"encrypted" type:"boolean"` - // The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) - // customer master key (CMK) that was used to protect the volume encryption - // key for the parent volume. + // The full ARN of the AWS Key Management Service (AWS KMS) customer master + // key (CMK) that was used to protect the volume encryption key for the parent + // volume. KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // Value from an Amazon-maintained list (amazon | self | all | aws-marketplace - // | microsoft) of snapshot owners. Not to be confused with the user-configured - // AWS account alias, which is set from the IAM console. + // Value from an Amazon-maintained list (amazon | aws-marketplace | microsoft) + // of snapshot owners. Not to be confused with the user-configured AWS account + // alias, which is set from the IAM console. OwnerAlias *string `locationName:"ownerAlias" type:"string"` // The AWS account ID of the EBS snapshot owner. @@ -85493,7 +64797,7 @@ type Snapshot struct { // operation fails (for example, if the proper AWS Key Management Service (AWS // KMS) permissions are not obtained) this field displays error state details // to help you diagnose why the error occurred. This parameter is only returned - // by DescribeSnapshots. + // by the DescribeSnapshots API operation. StateMessage *string `locationName:"statusMessage" type:"string"` // Any tags assigned to the snapshot. @@ -85716,7 +65020,7 @@ type SnapshotDiskContainer struct { // The format of the disk image being imported. // - // Valid values: VHD | VMDK + // Valid values: VHD | VMDK | OVA Format *string `type:"string"` // The URL to the Amazon S3-based disk image being imported. It can either be @@ -85761,113 +65065,6 @@ func (s *SnapshotDiskContainer) SetUserBucket(v *UserBucket) *SnapshotDiskContai return s } -// Information about a snapshot. -type SnapshotInfo struct { - _ struct{} `type:"structure"` - - // Description specified by the CreateSnapshotRequest that has been applied - // to all snapshots. - Description *string `locationName:"description" type:"string"` - - // Indicates whether the snapshot is encrypted. - Encrypted *bool `locationName:"encrypted" type:"boolean"` - - // Account id used when creating this snapshot. - OwnerId *string `locationName:"ownerId" type:"string"` - - // Progress this snapshot has made towards completing. - Progress *string `locationName:"progress" type:"string"` - - // Snapshot id that can be used to describe this snapshot. - SnapshotId *string `locationName:"snapshotId" type:"string"` - - // Time this snapshot was started. This is the same for all snapshots initiated - // by the same request. - StartTime *time.Time `locationName:"startTime" type:"timestamp"` - - // Current state of the snapshot. - State *string `locationName:"state" type:"string" enum:"SnapshotState"` - - // Tags associated with this snapshot. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // Source volume from which this snapshot was created. - VolumeId *string `locationName:"volumeId" type:"string"` - - // Size of the volume from which this snapshot was created. - VolumeSize *int64 `locationName:"volumeSize" type:"integer"` -} - -// String returns the string representation -func (s SnapshotInfo) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s SnapshotInfo) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *SnapshotInfo) SetDescription(v string) *SnapshotInfo { - s.Description = &v - return s -} - -// SetEncrypted sets the Encrypted field's value. -func (s *SnapshotInfo) SetEncrypted(v bool) *SnapshotInfo { - s.Encrypted = &v - return s -} - -// SetOwnerId sets the OwnerId field's value. -func (s *SnapshotInfo) SetOwnerId(v string) *SnapshotInfo { - s.OwnerId = &v - return s -} - -// SetProgress sets the Progress field's value. -func (s *SnapshotInfo) SetProgress(v string) *SnapshotInfo { - s.Progress = &v - return s -} - -// SetSnapshotId sets the SnapshotId field's value. -func (s *SnapshotInfo) SetSnapshotId(v string) *SnapshotInfo { - s.SnapshotId = &v - return s -} - -// SetStartTime sets the StartTime field's value. -func (s *SnapshotInfo) SetStartTime(v time.Time) *SnapshotInfo { - s.StartTime = &v - return s -} - -// SetState sets the State field's value. -func (s *SnapshotInfo) SetState(v string) *SnapshotInfo { - s.State = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *SnapshotInfo) SetTags(v []*Tag) *SnapshotInfo { - s.Tags = v - return s -} - -// SetVolumeId sets the VolumeId field's value. -func (s *SnapshotInfo) SetVolumeId(v string) *SnapshotInfo { - s.VolumeId = &v - return s -} - -// SetVolumeSize sets the VolumeSize field's value. -func (s *SnapshotInfo) SetVolumeSize(v int64) *SnapshotInfo { - s.VolumeSize = &v - return s -} - // Details about the import snapshot task. type SnapshotTaskDetail struct { _ struct{} `type:"structure"` @@ -85878,16 +65075,9 @@ type SnapshotTaskDetail struct { // The size of the disk in the snapshot, in GiB. DiskImageSize *float64 `locationName:"diskImageSize" type:"double"` - // Indicates whether the snapshot is encrypted. - Encrypted *bool `locationName:"encrypted" type:"boolean"` - // The format of the disk image from which the snapshot is created. Format *string `locationName:"format" type:"string"` - // The identifier for the AWS Key Management Service (AWS KMS) customer master - // key (CMK) that was used to create the encrypted snapshot. - KmsKeyId *string `locationName:"kmsKeyId" type:"string"` - // The percentage of completion for the import snapshot task. Progress *string `locationName:"progress" type:"string"` @@ -85929,24 +65119,12 @@ func (s *SnapshotTaskDetail) SetDiskImageSize(v float64) *SnapshotTaskDetail { return s } -// SetEncrypted sets the Encrypted field's value. -func (s *SnapshotTaskDetail) SetEncrypted(v bool) *SnapshotTaskDetail { - s.Encrypted = &v - return s -} - // SetFormat sets the Format field's value. func (s *SnapshotTaskDetail) SetFormat(v string) *SnapshotTaskDetail { s.Format = &v return s } -// SetKmsKeyId sets the KmsKeyId field's value. -func (s *SnapshotTaskDetail) SetKmsKeyId(v string) *SnapshotTaskDetail { - s.KmsKeyId = &v - return s -} - // SetProgress sets the Progress field's value. func (s *SnapshotTaskDetail) SetProgress(v string) *SnapshotTaskDetail { s.Progress = &v @@ -86043,20 +65221,17 @@ func (s *SpotDatafeedSubscription) SetState(v string) *SpotDatafeedSubscription return s } -// Describes the launch specification for one or more Spot Instances. If you -// include On-Demand capacity in your fleet request, you can't use SpotFleetLaunchSpecification; -// you must use LaunchTemplateConfig (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_LaunchTemplateConfig.html). +// Describes the launch specification for one or more Spot Instances. type SpotFleetLaunchSpecification struct { _ struct{} `type:"structure"` // Deprecated. AddressingType *string `locationName:"addressingType" type:"string"` - // One or more block devices that are mapped to the Spot instances. You can't - // specify both a snapshot ID and an encryption value. This is because only - // blank volumes can be encrypted on creation. If a snapshot is the basis for - // a volume, it is not blank and its encryption status is used for the volume - // encryption status. + // One or more block device mapping entries. You can't specify both a snapshot + // ID and an encryption value. This is because only blank volumes can be encrypted + // on creation. If a snapshot is the basis for a volume, it is not blank and + // its encryption status is used for the volume encryption status. BlockDeviceMappings []*BlockDeviceMapping `locationName:"blockDeviceMapping" locationNameList:"item" type:"list"` // Indicates whether the instances are optimized for EBS I/O. This optimization @@ -86093,10 +65268,7 @@ type SpotFleetLaunchSpecification struct { // The placement information. Placement *SpotPlacement `locationName:"placement" type:"structure"` - // The ID of the RAM disk. Some kernels require additional drivers at launch. - // Check the kernel requirements for information about whether you need to specify - // a RAM disk. To find kernel requirements, refer to the AWS Resource Center - // and search for the kernel ID. + // The ID of the RAM disk. RamdiskId *string `locationName:"ramdiskId" type:"string"` // One or more security groups. When requesting instances in a VPC, you must @@ -86117,16 +65289,16 @@ type SpotFleetLaunchSpecification struct { // The tags to apply during creation. TagSpecifications []*SpotFleetTagSpecification `locationName:"tagSpecificationSet" locationNameList:"item" type:"list"` - // The Base64-encoded user data that instances use when starting up. + // The Base64-encoded user data to make available to the instances. UserData *string `locationName:"userData" type:"string"` // The number of units provided by the specified instance type. These are the - // same units that you chose to set the target capacity in terms of instances, - // or a performance characteristic such as vCPUs, memory, or I/O. + // same units that you chose to set the target capacity in terms (instances + // or a performance characteristic such as vCPUs, memory, or I/O). // - // If the target capacity divided by this value is not a whole number, Amazon - // EC2 rounds the number of instances to the next whole number. If this value - // is not specified, the default is 1. + // If the target capacity divided by this value is not a whole number, we round + // the number of instances to the next whole number. If this value is not specified, + // the default is 1. WeightedCapacity *float64 `locationName:"weightedCapacity" type:"double"` } @@ -86286,16 +65458,24 @@ type SpotFleetRequestConfig struct { ActivityStatus *string `locationName:"activityStatus" type:"string" enum:"ActivityStatus"` // The creation date and time of the request. - CreateTime *time.Time `locationName:"createTime" type:"timestamp"` + // + // CreateTime is a required field + CreateTime *time.Time `locationName:"createTime" type:"timestamp" required:"true"` // The configuration of the Spot Fleet request. - SpotFleetRequestConfig *SpotFleetRequestConfigData `locationName:"spotFleetRequestConfig" type:"structure"` + // + // SpotFleetRequestConfig is a required field + SpotFleetRequestConfig *SpotFleetRequestConfigData `locationName:"spotFleetRequestConfig" type:"structure" required:"true"` // The ID of the Spot Fleet request. - SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string"` + // + // SpotFleetRequestId is a required field + SpotFleetRequestId *string `locationName:"spotFleetRequestId" type:"string" required:"true"` // The state of the Spot Fleet request. - SpotFleetRequestState *string `locationName:"spotFleetRequestState" type:"string" enum:"BatchState"` + // + // SpotFleetRequestState is a required field + SpotFleetRequestState *string `locationName:"spotFleetRequestState" type:"string" required:"true" enum:"BatchState"` } // String returns the string representation @@ -86348,26 +65528,21 @@ type SpotFleetRequestConfigData struct { // A unique, case-sensitive identifier that you provide to ensure the idempotency // of your listings. This helps to avoid duplicate listings. For more information, - // see Ensuring Idempotency (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). + // see Ensuring Idempotency (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html). ClientToken *string `locationName:"clientToken" type:"string"` - // Indicates whether running Spot Instances should be terminated if you decrease - // the target capacity of the Spot Fleet request below the current size of the - // Spot Fleet. + // Indicates whether running Spot Instances should be terminated if the target + // capacity of the Spot Fleet request is decreased below the current size of + // the Spot Fleet. ExcessCapacityTerminationPolicy *string `locationName:"excessCapacityTerminationPolicy" type:"string" enum:"ExcessCapacityTerminationPolicy"` // The number of units fulfilled by this request compared to the set target - // capacity. You cannot set this value. + // capacity. FulfilledCapacity *float64 `locationName:"fulfilledCapacity" type:"double"` - // The Amazon Resource Name (ARN) of an AWS Identity and Access Management (IAM) - // role that grants the Spot Fleet the permission to request, launch, terminate, - // and tag instances on your behalf. For more information, see Spot Fleet Prerequisites - // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-fleet-requests.html#spot-fleet-prerequisites) - // in the Amazon EC2 User Guide for Linux Instances. Spot Fleet can terminate - // Spot Instances on your behalf when you cancel its Spot Fleet request using - // CancelSpotFleetRequests or when the Spot Fleet request expires, if you set - // TerminateInstancesWithExpiration. + // Grants the Spot Fleet permission to terminate Spot Instances on your behalf + // when you cancel its Spot Fleet request using CancelSpotFleetRequests or when + // the Spot Fleet request expires, if you set terminateInstancesWithExpiration. // // IamFleetRole is a required field IamFleetRole *string `locationName:"iamFleetRole" type:"string" required:"true"` @@ -86381,14 +65556,10 @@ type SpotFleetRequestConfigData struct { // across the number of Spot pools that you specify. InstancePoolsToUseCount *int64 `locationName:"instancePoolsToUseCount" type:"integer"` - // The launch specifications for the Spot Fleet request. If you specify LaunchSpecifications, - // you can't specify LaunchTemplateConfigs. If you include On-Demand capacity - // in your request, you must use LaunchTemplateConfigs. + // The launch specifications for the Spot Fleet request. LaunchSpecifications []*SpotFleetLaunchSpecification `locationName:"launchSpecifications" locationNameList:"item" type:"list"` - // The launch template and overrides. If you specify LaunchTemplateConfigs, - // you can't specify LaunchSpecifications. If you include On-Demand capacity - // in your request, you must use LaunchTemplateConfigs. + // The launch template and overrides. LaunchTemplateConfigs []*LaunchTemplateConfig `locationName:"launchTemplateConfigs" locationNameList:"item" type:"list"` // One or more Classic Load Balancers and target groups to attach to the Spot @@ -86412,16 +65583,6 @@ type SpotFleetRequestConfigData struct { // target On-Demand capacity. OnDemandFulfilledCapacity *float64 `locationName:"onDemandFulfilledCapacity" type:"double"` - // The maximum amount per hour for On-Demand Instances that you're willing to - // pay. You can use the onDemandMaxTotalPrice parameter, the spotMaxTotalPrice - // parameter, or both parameters to ensure that your fleet cost does not exceed - // your budget. If you set a maximum price per hour for the On-Demand Instances - // and Spot Instances in your request, Spot Fleet will launch instances until - // it reaches the maximum amount you're willing to pay. When the maximum amount - // you're willing to pay is reached, the fleet stops launching instances even - // if it hasn’t met the target capacity. - OnDemandMaxTotalPrice *string `locationName:"onDemandMaxTotalPrice" type:"string"` - // The number of On-Demand units to request. You can choose to set the target // capacity in terms of instances or a performance characteristic that is important // to your application workload, such as vCPUs, memory, or I/O. If the request @@ -86432,51 +65593,39 @@ type SpotFleetRequestConfigData struct { // Indicates whether Spot Fleet should replace unhealthy instances. ReplaceUnhealthyInstances *bool `locationName:"replaceUnhealthyInstances" type:"boolean"` - // The maximum amount per hour for Spot Instances that you're willing to pay. - // You can use the spotdMaxTotalPrice parameter, the onDemandMaxTotalPrice parameter, - // or both parameters to ensure that your fleet cost does not exceed your budget. - // If you set a maximum price per hour for the On-Demand Instances and Spot - // Instances in your request, Spot Fleet will launch instances until it reaches - // the maximum amount you're willing to pay. When the maximum amount you're - // willing to pay is reached, the fleet stops launching instances even if it - // hasn’t met the target capacity. - SpotMaxTotalPrice *string `locationName:"spotMaxTotalPrice" type:"string"` - // The maximum price per unit hour that you are willing to pay for a Spot Instance. // The default is the On-Demand price. SpotPrice *string `locationName:"spotPrice" type:"string"` - // The number of units to request for the Spot Fleet. You can choose to set - // the target capacity in terms of instances or a performance characteristic - // that is important to your application workload, such as vCPUs, memory, or - // I/O. If the request type is maintain, you can specify a target capacity of - // 0 and add capacity later. + // The number of units to request. You can choose to set the target capacity + // in terms of instances or a performance characteristic that is important to + // your application workload, such as vCPUs, memory, or I/O. If the request + // type is maintain, you can specify a target capacity of 0 and add capacity + // later. // // TargetCapacity is a required field TargetCapacity *int64 `locationName:"targetCapacity" type:"integer" required:"true"` - // Indicates whether running Spot Instances are terminated when the Spot Fleet - // request expires. + // Indicates whether running Spot Instances should be terminated when the Spot + // Fleet request expires. TerminateInstancesWithExpiration *bool `locationName:"terminateInstancesWithExpiration" type:"boolean"` // The type of request. Indicates whether the Spot Fleet only requests the target // capacity or also attempts to maintain it. When this value is request, the // Spot Fleet only places the required requests. It does not attempt to replenish // Spot Instances if capacity is diminished, nor does it submit requests in - // alternative Spot pools if capacity is not available. When this value is maintain, - // the Spot Fleet maintains the target capacity. The Spot Fleet places the required - // requests to meet capacity and automatically replenishes any interrupted instances. - // Default: maintain. instant is listed but is not used by Spot Fleet. + // alternative Spot pools if capacity is not available. To maintain a certain + // target capacity, the Spot Fleet places the required requests to meet capacity + // and automatically replenishes any interrupted instances. Default: maintain. Type *string `locationName:"type" type:"string" enum:"FleetType"` - // The start date and time of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). - // By default, Amazon EC2 starts fulfilling the request immediately. + // The start date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). + // The default is to start fulfilling the request immediately. ValidFrom *time.Time `locationName:"validFrom" type:"timestamp"` - // The end date and time of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). - // After the end date and time, no new Spot Instance requests are placed or - // able to fulfill the request. If no value is specified, the Spot Fleet request - // remains until you cancel it. + // The end date and time of the request, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). + // At this point, no new Spot Instance requests are placed or able to fulfill + // the request. The default end date is 7 days from the current date. ValidUntil *time.Time `locationName:"validUntil" type:"timestamp"` } @@ -86593,12 +65742,6 @@ func (s *SpotFleetRequestConfigData) SetOnDemandFulfilledCapacity(v float64) *Sp return s } -// SetOnDemandMaxTotalPrice sets the OnDemandMaxTotalPrice field's value. -func (s *SpotFleetRequestConfigData) SetOnDemandMaxTotalPrice(v string) *SpotFleetRequestConfigData { - s.OnDemandMaxTotalPrice = &v - return s -} - // SetOnDemandTargetCapacity sets the OnDemandTargetCapacity field's value. func (s *SpotFleetRequestConfigData) SetOnDemandTargetCapacity(v int64) *SpotFleetRequestConfigData { s.OnDemandTargetCapacity = &v @@ -86611,12 +65754,6 @@ func (s *SpotFleetRequestConfigData) SetReplaceUnhealthyInstances(v bool) *SpotF return s } -// SetSpotMaxTotalPrice sets the SpotMaxTotalPrice field's value. -func (s *SpotFleetRequestConfigData) SetSpotMaxTotalPrice(v string) *SpotFleetRequestConfigData { - s.SpotMaxTotalPrice = &v - return s -} - // SetSpotPrice sets the SpotPrice field's value. func (s *SpotFleetRequestConfigData) SetSpotPrice(v string) *SpotFleetRequestConfigData { s.SpotPrice = &v @@ -86737,7 +65874,7 @@ type SpotInstanceRequest struct { SpotPrice *string `locationName:"spotPrice" type:"string"` // The state of the Spot Instance request. Spot status information helps track - // your Spot Instance requests. For more information, see Spot Status (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html) + // your Spot Instance requests. For more information, see Spot Status (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html) // in the Amazon EC2 User Guide for Linux Instances. State *string `locationName:"state" type:"string" enum:"SpotInstanceState"` @@ -86923,7 +66060,7 @@ func (s *SpotInstanceStateFault) SetMessage(v string) *SpotInstanceStateFault { type SpotInstanceStatus struct { _ struct{} `type:"structure"` - // The status code. For a list of status codes, see Spot Status Codes (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html#spot-instance-bid-status-understand) + // The status code. For a list of status codes, see Spot Status Codes (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-bid-status.html#spot-instance-bid-status-understand) // in the Amazon EC2 User Guide for Linux Instances. Code *string `locationName:"code" type:"string"` @@ -87048,21 +66185,6 @@ type SpotOptions struct { // the cheapest Spot pools and evenly allocates your target Spot capacity across // the number of Spot pools that you specify. InstancePoolsToUseCount *int64 `locationName:"instancePoolsToUseCount" type:"integer"` - - // The maximum amount per hour for Spot Instances that you're willing to pay. - MaxTotalPrice *string `locationName:"maxTotalPrice" type:"string"` - - // The minimum target capacity for Spot Instances in the fleet. If the minimum - // target capacity is not reached, the fleet launches no instances. - MinTargetCapacity *int64 `locationName:"minTargetCapacity" type:"integer"` - - // Indicates that the fleet launches all Spot Instances into a single Availability - // Zone. - SingleAvailabilityZone *bool `locationName:"singleAvailabilityZone" type:"boolean"` - - // Indicates that the fleet uses a single instance type to launch all Spot Instances - // in the fleet. - SingleInstanceType *bool `locationName:"singleInstanceType" type:"boolean"` } // String returns the string representation @@ -87093,30 +66215,6 @@ func (s *SpotOptions) SetInstancePoolsToUseCount(v int64) *SpotOptions { return s } -// SetMaxTotalPrice sets the MaxTotalPrice field's value. -func (s *SpotOptions) SetMaxTotalPrice(v string) *SpotOptions { - s.MaxTotalPrice = &v - return s -} - -// SetMinTargetCapacity sets the MinTargetCapacity field's value. -func (s *SpotOptions) SetMinTargetCapacity(v int64) *SpotOptions { - s.MinTargetCapacity = &v - return s -} - -// SetSingleAvailabilityZone sets the SingleAvailabilityZone field's value. -func (s *SpotOptions) SetSingleAvailabilityZone(v bool) *SpotOptions { - s.SingleAvailabilityZone = &v - return s -} - -// SetSingleInstanceType sets the SingleInstanceType field's value. -func (s *SpotOptions) SetSingleInstanceType(v bool) *SpotOptions { - s.SingleInstanceType = &v - return s -} - // Describes the configuration of Spot Instances in an EC2 Fleet request. type SpotOptionsRequest struct { _ struct{} `type:"structure"` @@ -87133,21 +66231,6 @@ type SpotOptionsRequest struct { // selects the cheapest Spot pools and evenly allocates your target Spot capacity // across the number of Spot pools that you specify. InstancePoolsToUseCount *int64 `type:"integer"` - - // The maximum amount per hour for Spot Instances that you're willing to pay. - MaxTotalPrice *string `type:"string"` - - // The minimum target capacity for Spot Instances in the fleet. If the minimum - // target capacity is not reached, the fleet launches no instances. - MinTargetCapacity *int64 `type:"integer"` - - // Indicates that the fleet launches all Spot Instances into a single Availability - // Zone. - SingleAvailabilityZone *bool `type:"boolean"` - - // Indicates that the fleet uses a single instance type to launch all Spot Instances - // in the fleet. - SingleInstanceType *bool `type:"boolean"` } // String returns the string representation @@ -87178,30 +66261,6 @@ func (s *SpotOptionsRequest) SetInstancePoolsToUseCount(v int64) *SpotOptionsReq return s } -// SetMaxTotalPrice sets the MaxTotalPrice field's value. -func (s *SpotOptionsRequest) SetMaxTotalPrice(v string) *SpotOptionsRequest { - s.MaxTotalPrice = &v - return s -} - -// SetMinTargetCapacity sets the MinTargetCapacity field's value. -func (s *SpotOptionsRequest) SetMinTargetCapacity(v int64) *SpotOptionsRequest { - s.MinTargetCapacity = &v - return s -} - -// SetSingleAvailabilityZone sets the SingleAvailabilityZone field's value. -func (s *SpotOptionsRequest) SetSingleAvailabilityZone(v bool) *SpotOptionsRequest { - s.SingleAvailabilityZone = &v - return s -} - -// SetSingleInstanceType sets the SingleInstanceType field's value. -func (s *SpotOptionsRequest) SetSingleInstanceType(v bool) *SpotOptionsRequest { - s.SingleInstanceType = &v - return s -} - // Describes Spot Instance placement. type SpotPlacement struct { _ struct{} `type:"structure"` @@ -87322,19 +66381,19 @@ type StaleIpPermission struct { // (http://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml). IpProtocol *string `locationName:"ipProtocol" type:"string"` - // The IP ranges. Not applicable for stale security group rules. + // One or more IP ranges. Not applicable for stale security group rules. IpRanges []*string `locationName:"ipRanges" locationNameList:"item" type:"list"` - // The prefix list IDs for an AWS service. Not applicable for stale security - // group rules. + // One or more prefix list IDs for an AWS service. Not applicable for stale + // security group rules. PrefixListIds []*string `locationName:"prefixListIds" locationNameList:"item" type:"list"` // The end of the port range for the TCP and UDP protocols, or an ICMP type // number. A value of -1 indicates all ICMP types. ToPort *int64 `locationName:"toPort" type:"integer"` - // The security group pairs. Returns the ID of the referenced security group - // and VPC, and the ID and status of the VPC peering connection. + // One or more security group pairs. Returns the ID of the referenced security + // group and VPC, and the ID and status of the VPC peering connection. UserIdGroupPairs []*UserIdGroupPair `locationName:"groups" locationNameList:"item" type:"list"` } @@ -87392,7 +66451,9 @@ type StaleSecurityGroup struct { Description *string `locationName:"description" type:"string"` // The ID of the security group. - GroupId *string `locationName:"groupId" type:"string"` + // + // GroupId is a required field + GroupId *string `locationName:"groupId" type:"string" required:"true"` // The name of the security group. GroupName *string `locationName:"groupName" type:"string"` @@ -87453,6 +66514,7 @@ func (s *StaleSecurityGroup) SetVpcId(v string) *StaleSecurityGroup { return s } +// Contains the parameters for StartInstances. type StartInstancesInput struct { _ struct{} `type:"structure"` @@ -87465,7 +66527,7 @@ type StartInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the instances. + // One or more instance IDs. // // InstanceIds is a required field InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` @@ -87512,10 +66574,11 @@ func (s *StartInstancesInput) SetInstanceIds(v []*string) *StartInstancesInput { return s } +// Contains the output of StartInstances. type StartInstancesOutput struct { _ struct{} `type:"structure"` - // Information about the started instances. + // Information about one or more started instances. StartingInstances []*InstanceStateChange `locationName:"instancesSet" locationNameList:"item" type:"list"` } @@ -87573,8 +66636,6 @@ type StateReason struct { // // * Client.InvalidSnapshot.NotFound: The specified snapshot was not found. // - // * Client.UserInitiatedHibernate: Hibernation was initiated on the instance. - // // * Client.UserInitiatedShutdown: The instance was shut down using the Amazon // EC2 API. // @@ -87606,6 +66667,7 @@ func (s *StateReason) SetMessage(v string) *StateReason { return s } +// Contains the parameters for StopInstances. type StopInstancesInput struct { _ struct{} `type:"structure"` @@ -87623,15 +66685,7 @@ type StopInstancesInput struct { // Default: false Force *bool `locationName:"force" type:"boolean"` - // Hibernates the instance if the instance was enabled for hibernation at launch. - // If the instance cannot hibernate successfully, a normal shutdown occurs. - // For more information, see Hibernate Your Instance (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Hibernate.html) - // in the Amazon Elastic Compute Cloud User Guide. - // - // Default: false - Hibernate *bool `type:"boolean"` - - // The IDs of the instances. + // One or more instance IDs. // // InstanceIds is a required field InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` @@ -87672,22 +66726,17 @@ func (s *StopInstancesInput) SetForce(v bool) *StopInstancesInput { return s } -// SetHibernate sets the Hibernate field's value. -func (s *StopInstancesInput) SetHibernate(v bool) *StopInstancesInput { - s.Hibernate = &v - return s -} - // SetInstanceIds sets the InstanceIds field's value. func (s *StopInstancesInput) SetInstanceIds(v []*string) *StopInstancesInput { s.InstanceIds = v return s } +// Contains the output of StopInstances. type StopInstancesOutput struct { _ struct{} `type:"structure"` - // Information about the stopped instances. + // Information about one or more stopped instances. StoppingInstances []*InstanceStateChange `locationName:"instancesSet" locationNameList:"item" type:"list"` } @@ -87775,9 +66824,6 @@ type Subnet struct { // The Availability Zone of the subnet. AvailabilityZone *string `locationName:"availabilityZone" type:"string"` - // The AZ ID of the subnet. - AvailabilityZoneId *string `locationName:"availabilityZoneId" type:"string"` - // The number of unused private IPv4 addresses in the subnet. The IPv4 addresses // for any stopped instances are considered unavailable. AvailableIpAddressCount *int64 `locationName:"availableIpAddressCount" type:"integer"` @@ -87795,15 +66841,9 @@ type Subnet struct { // address. MapPublicIpOnLaunch *bool `locationName:"mapPublicIpOnLaunch" type:"boolean"` - // The ID of the AWS account that owns the subnet. - OwnerId *string `locationName:"ownerId" type:"string"` - // The current state of the subnet. State *string `locationName:"state" type:"string" enum:"SubnetState"` - // The Amazon Resource Name (ARN) of the subnet. - SubnetArn *string `locationName:"subnetArn" type:"string"` - // The ID of the subnet. SubnetId *string `locationName:"subnetId" type:"string"` @@ -87836,12 +66876,6 @@ func (s *Subnet) SetAvailabilityZone(v string) *Subnet { return s } -// SetAvailabilityZoneId sets the AvailabilityZoneId field's value. -func (s *Subnet) SetAvailabilityZoneId(v string) *Subnet { - s.AvailabilityZoneId = &v - return s -} - // SetAvailableIpAddressCount sets the AvailableIpAddressCount field's value. func (s *Subnet) SetAvailableIpAddressCount(v int64) *Subnet { s.AvailableIpAddressCount = &v @@ -87872,24 +66906,12 @@ func (s *Subnet) SetMapPublicIpOnLaunch(v bool) *Subnet { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *Subnet) SetOwnerId(v string) *Subnet { - s.OwnerId = &v - return s -} - // SetState sets the State field's value. func (s *Subnet) SetState(v string) *Subnet { s.State = &v return s } -// SetSubnetArn sets the SubnetArn field's value. -func (s *Subnet) SetSubnetArn(v string) *Subnet { - s.SubnetArn = &v - return s -} - // SetSubnetId sets the SubnetId field's value. func (s *Subnet) SetSubnetId(v string) *Subnet { s.SubnetId = &v @@ -87983,7 +67005,7 @@ func (s *SubnetIpv6CidrBlockAssociation) SetIpv6CidrBlockState(v *SubnetCidrBloc return s } -// Describes the T2 or T3 instance whose credit option for CPU usage was successfully +// Describes the T2 instance whose credit option for CPU usage was successfully // modified. type SuccessfulInstanceCreditSpecificationItem struct { _ struct{} `type:"structure"` @@ -88015,7 +67037,7 @@ type Tag struct { // The key of the tag. // // Constraints: Tag keys are case-sensitive and accept a maximum of 127 Unicode - // characters. May not begin with aws:. + // characters. May not begin with aws: Key *string `locationName:"key" type:"string"` // The value of the tag. @@ -88054,7 +67076,7 @@ type TagDescription struct { // The tag key. Key *string `locationName:"key" type:"string"` - // The ID of the resource. + // The ID of the resource. For example, ami-1a2b3c4d. ResourceId *string `locationName:"resourceId" type:"string"` // The resource type. @@ -88103,8 +67125,8 @@ type TagSpecification struct { _ struct{} `type:"structure"` // The type of resource to tag. Currently, the resource types that support tagging - // on creation are fleet, dedicated-host, instance, snapshot, and volume. To - // tag a resource after it has been created, see CreateTags. + // on creation are fleet, instance, snapshot, and volume. To tag a resource + // after it has been created, see CreateTags. ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` // The tags to apply to the resource. @@ -88138,27 +67160,16 @@ func (s *TagSpecification) SetTags(v []*Tag) *TagSpecification { // your application workload, such as vCPUs, memory, or I/O. If the request // type is maintain, you can specify a target capacity of 0 and add capacity // later. -// -// You can use the On-Demand Instance MaxTotalPrice parameter, the Spot Instance -// MaxTotalPrice, or both to ensure your fleet cost does not exceed your budget. -// If you set a maximum price per hour for the On-Demand Instances and Spot -// Instances in your request, EC2 Fleet will launch instances until it reaches -// the maximum amount you're willing to pay. When the maximum amount you're -// willing to pay is reached, the fleet stops launching instances even if it -// hasn’t met the target capacity. The MaxTotalPrice parameters are located -// in and type TargetCapacitySpecification struct { _ struct{} `type:"structure"` // The default TotalTargetCapacity, which is either Spot or On-Demand. DefaultTargetCapacityType *string `locationName:"defaultTargetCapacityType" type:"string" enum:"DefaultTargetCapacityType"` - // The number of On-Demand units to request. If you specify a target capacity - // for Spot units, you cannot specify a target capacity for On-Demand units. + // The number of On-Demand units to request. OnDemandTargetCapacity *int64 `locationName:"onDemandTargetCapacity" type:"integer"` - // The maximum number of Spot units to launch. If you specify a target capacity - // for On-Demand units, you cannot specify a target capacity for Spot units. + // The maximum number of Spot units to launch. SpotTargetCapacity *int64 `locationName:"spotTargetCapacity" type:"integer"` // The number of units to request, filled using DefaultTargetCapacityType. @@ -88200,19 +67211,10 @@ func (s *TargetCapacitySpecification) SetTotalTargetCapacity(v int64) *TargetCap } // The number of units to request. You can choose to set the target capacity -// as the number of instances. Or you can set the target capacity to a performance -// characteristic that is important to your application workload, such as vCPUs, -// memory, or I/O. If the request type is maintain, you can specify a target -// capacity of 0 and add capacity later. -// -// You can use the On-Demand Instance MaxTotalPrice parameter, the Spot Instance -// MaxTotalPrice parameter, or both parameters to ensure that your fleet cost -// does not exceed your budget. If you set a maximum price per hour for the -// On-Demand Instances and Spot Instances in your request, EC2 Fleet will launch -// instances until it reaches the maximum amount you're willing to pay. When -// the maximum amount you're willing to pay is reached, the fleet stops launching -// instances even if it hasn’t met the target capacity. The MaxTotalPrice -// parameters are located in and . +// in terms of instances or a performance characteristic that is important to +// your application workload, such as vCPUs, memory, or I/O. If the request +// type is maintain, you can specify a target capacity of 0 and add capacity +// later. type TargetCapacitySpecificationRequest struct { _ struct{} `type:"structure"` @@ -88366,7 +67368,9 @@ type TargetGroup struct { _ struct{} `type:"structure"` // The Amazon Resource Name (ARN) of the target group. - Arn *string `locationName:"arn" type:"string"` + // + // Arn is a required field + Arn *string `locationName:"arn" type:"string" required:"true"` } // String returns the string representation @@ -88379,6 +67383,19 @@ func (s TargetGroup) GoString() string { return s.String() } +// Validate inspects the fields of the type to determine if they are valid. +func (s *TargetGroup) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TargetGroup"} + if s.Arn == nil { + invalidParams.Add(request.NewErrParamRequired("Arn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + // SetArn sets the Arn field's value. func (s *TargetGroup) SetArn(v string) *TargetGroup { s.Arn = &v @@ -88391,7 +67408,9 @@ type TargetGroupsConfig struct { _ struct{} `type:"structure"` // One or more target groups. - TargetGroups []*TargetGroup `locationName:"targetGroups" locationNameList:"item" min:"1" type:"list"` + // + // TargetGroups is a required field + TargetGroups []*TargetGroup `locationName:"targetGroups" locationNameList:"item" min:"1" type:"list" required:"true"` } // String returns the string representation @@ -88407,9 +67426,22 @@ func (s TargetGroupsConfig) GoString() string { // Validate inspects the fields of the type to determine if they are valid. func (s *TargetGroupsConfig) Validate() error { invalidParams := request.ErrInvalidParams{Context: "TargetGroupsConfig"} + if s.TargetGroups == nil { + invalidParams.Add(request.NewErrParamRequired("TargetGroups")) + } if s.TargetGroups != nil && len(s.TargetGroups) < 1 { invalidParams.Add(request.NewErrParamMinLen("TargetGroups", 1)) } + if s.TargetGroups != nil { + for i, v := range s.TargetGroups { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TargetGroups", i), err.(request.ErrInvalidParams)) + } + } + } if invalidParams.Len() > 0 { return invalidParams @@ -88423,75 +67455,6 @@ func (s *TargetGroupsConfig) SetTargetGroups(v []*TargetGroup) *TargetGroupsConf return s } -// Describes a target network associated with a Client VPN endpoint. -type TargetNetwork struct { - _ struct{} `type:"structure"` - - // The ID of the association. - AssociationId *string `locationName:"associationId" type:"string"` - - // The ID of the Client VPN endpoint with which the target network is associated. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // The IDs of the security groups applied to the target network association. - SecurityGroups []*string `locationName:"securityGroups" locationNameList:"item" type:"list"` - - // The current state of the target network association. - Status *AssociationStatus `locationName:"status" type:"structure"` - - // The ID of the subnet specified as the target network. - TargetNetworkId *string `locationName:"targetNetworkId" type:"string"` - - // The ID of the VPC in which the target network (subnet) is located. - VpcId *string `locationName:"vpcId" type:"string"` -} - -// String returns the string representation -func (s TargetNetwork) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TargetNetwork) GoString() string { - return s.String() -} - -// SetAssociationId sets the AssociationId field's value. -func (s *TargetNetwork) SetAssociationId(v string) *TargetNetwork { - s.AssociationId = &v - return s -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *TargetNetwork) SetClientVpnEndpointId(v string) *TargetNetwork { - s.ClientVpnEndpointId = &v - return s -} - -// SetSecurityGroups sets the SecurityGroups field's value. -func (s *TargetNetwork) SetSecurityGroups(v []*string) *TargetNetwork { - s.SecurityGroups = v - return s -} - -// SetStatus sets the Status field's value. -func (s *TargetNetwork) SetStatus(v *AssociationStatus) *TargetNetwork { - s.Status = v - return s -} - -// SetTargetNetworkId sets the TargetNetworkId field's value. -func (s *TargetNetwork) SetTargetNetworkId(v string) *TargetNetwork { - s.TargetNetworkId = &v - return s -} - -// SetVpcId sets the VpcId field's value. -func (s *TargetNetwork) SetVpcId(v string) *TargetNetwork { - s.VpcId = &v - return s -} - // The total value of the new Convertible Reserved Instances. type TargetReservationValue struct { _ struct{} `type:"structure"` @@ -88528,159 +67491,7 @@ func (s *TargetReservationValue) SetTargetConfiguration(v *TargetConfiguration) return s } -type TerminateClientVpnConnectionsInput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint to which the client is connected. - // - // ClientVpnEndpointId is a required field - ClientVpnEndpointId *string `type:"string" required:"true"` - - // The ID of the client connection to be terminated. - ConnectionId *string `type:"string"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` - - // The name of the user who initiated the connection. Use this option to terminate - // all active connections for the specified user. This option can only be used - // if the user has established up to five connections. - Username *string `type:"string"` -} - -// String returns the string representation -func (s TerminateClientVpnConnectionsInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TerminateClientVpnConnectionsInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *TerminateClientVpnConnectionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "TerminateClientVpnConnectionsInput"} - if s.ClientVpnEndpointId == nil { - invalidParams.Add(request.NewErrParamRequired("ClientVpnEndpointId")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *TerminateClientVpnConnectionsInput) SetClientVpnEndpointId(v string) *TerminateClientVpnConnectionsInput { - s.ClientVpnEndpointId = &v - return s -} - -// SetConnectionId sets the ConnectionId field's value. -func (s *TerminateClientVpnConnectionsInput) SetConnectionId(v string) *TerminateClientVpnConnectionsInput { - s.ConnectionId = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *TerminateClientVpnConnectionsInput) SetDryRun(v bool) *TerminateClientVpnConnectionsInput { - s.DryRun = &v - return s -} - -// SetUsername sets the Username field's value. -func (s *TerminateClientVpnConnectionsInput) SetUsername(v string) *TerminateClientVpnConnectionsInput { - s.Username = &v - return s -} - -type TerminateClientVpnConnectionsOutput struct { - _ struct{} `type:"structure"` - - // The ID of the Client VPN endpoint. - ClientVpnEndpointId *string `locationName:"clientVpnEndpointId" type:"string"` - - // The current state of the client connections. - ConnectionStatuses []*TerminateConnectionStatus `locationName:"connectionStatuses" locationNameList:"item" type:"list"` - - // The user who established the terminated client connections. - Username *string `locationName:"username" type:"string"` -} - -// String returns the string representation -func (s TerminateClientVpnConnectionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TerminateClientVpnConnectionsOutput) GoString() string { - return s.String() -} - -// SetClientVpnEndpointId sets the ClientVpnEndpointId field's value. -func (s *TerminateClientVpnConnectionsOutput) SetClientVpnEndpointId(v string) *TerminateClientVpnConnectionsOutput { - s.ClientVpnEndpointId = &v - return s -} - -// SetConnectionStatuses sets the ConnectionStatuses field's value. -func (s *TerminateClientVpnConnectionsOutput) SetConnectionStatuses(v []*TerminateConnectionStatus) *TerminateClientVpnConnectionsOutput { - s.ConnectionStatuses = v - return s -} - -// SetUsername sets the Username field's value. -func (s *TerminateClientVpnConnectionsOutput) SetUsername(v string) *TerminateClientVpnConnectionsOutput { - s.Username = &v - return s -} - -// Information about a terminated Client VPN endpoint client connection. -type TerminateConnectionStatus struct { - _ struct{} `type:"structure"` - - // The ID of the client connection. - ConnectionId *string `locationName:"connectionId" type:"string"` - - // A message about the status of the client connection, if applicable. - CurrentStatus *ClientVpnConnectionStatus `locationName:"currentStatus" type:"structure"` - - // The state of the client connection. - PreviousStatus *ClientVpnConnectionStatus `locationName:"previousStatus" type:"structure"` -} - -// String returns the string representation -func (s TerminateConnectionStatus) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TerminateConnectionStatus) GoString() string { - return s.String() -} - -// SetConnectionId sets the ConnectionId field's value. -func (s *TerminateConnectionStatus) SetConnectionId(v string) *TerminateConnectionStatus { - s.ConnectionId = &v - return s -} - -// SetCurrentStatus sets the CurrentStatus field's value. -func (s *TerminateConnectionStatus) SetCurrentStatus(v *ClientVpnConnectionStatus) *TerminateConnectionStatus { - s.CurrentStatus = v - return s -} - -// SetPreviousStatus sets the PreviousStatus field's value. -func (s *TerminateConnectionStatus) SetPreviousStatus(v *ClientVpnConnectionStatus) *TerminateConnectionStatus { - s.PreviousStatus = v - return s -} - +// Contains the parameters for TerminateInstances. type TerminateInstancesInput struct { _ struct{} `type:"structure"` @@ -88690,7 +67501,7 @@ type TerminateInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the instances. + // One or more instance IDs. // // Constraints: Up to 1000 instance IDs. We recommend breaking up this request // into smaller batches. @@ -88734,10 +67545,11 @@ func (s *TerminateInstancesInput) SetInstanceIds(v []*string) *TerminateInstance return s } +// Contains the output of TerminateInstances. type TerminateInstancesOutput struct { _ struct{} `type:"structure"` - // Information about the terminated instances. + // Information about one or more terminated instances. TerminatingInstances []*InstanceStateChange `locationName:"instancesSet" locationNameList:"item" type:"list"` } @@ -88757,1400 +67569,6 @@ func (s *TerminateInstancesOutput) SetTerminatingInstances(v []*InstanceStateCha return s } -// Describes the Traffic Mirror filter. -type TrafficMirrorFilter struct { - _ struct{} `type:"structure"` - - // The description of the Traffic Mirror filter. - Description *string `locationName:"description" type:"string"` - - // Information about the egress rules that are associated with the Traffic Mirror - // filter. - EgressFilterRules []*TrafficMirrorFilterRule `locationName:"egressFilterRuleSet" locationNameList:"item" type:"list"` - - // Information about the ingress rules that are associated with the Traffic - // Mirror filter. - IngressFilterRules []*TrafficMirrorFilterRule `locationName:"ingressFilterRuleSet" locationNameList:"item" type:"list"` - - // The network service traffic that is associated with the Traffic Mirror filter. - NetworkServices []*string `locationName:"networkServiceSet" locationNameList:"item" type:"list"` - - // The tags assigned to the Traffic Mirror filter. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the Traffic Mirror filter. - TrafficMirrorFilterId *string `locationName:"trafficMirrorFilterId" type:"string"` -} - -// String returns the string representation -func (s TrafficMirrorFilter) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorFilter) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *TrafficMirrorFilter) SetDescription(v string) *TrafficMirrorFilter { - s.Description = &v - return s -} - -// SetEgressFilterRules sets the EgressFilterRules field's value. -func (s *TrafficMirrorFilter) SetEgressFilterRules(v []*TrafficMirrorFilterRule) *TrafficMirrorFilter { - s.EgressFilterRules = v - return s -} - -// SetIngressFilterRules sets the IngressFilterRules field's value. -func (s *TrafficMirrorFilter) SetIngressFilterRules(v []*TrafficMirrorFilterRule) *TrafficMirrorFilter { - s.IngressFilterRules = v - return s -} - -// SetNetworkServices sets the NetworkServices field's value. -func (s *TrafficMirrorFilter) SetNetworkServices(v []*string) *TrafficMirrorFilter { - s.NetworkServices = v - return s -} - -// SetTags sets the Tags field's value. -func (s *TrafficMirrorFilter) SetTags(v []*Tag) *TrafficMirrorFilter { - s.Tags = v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *TrafficMirrorFilter) SetTrafficMirrorFilterId(v string) *TrafficMirrorFilter { - s.TrafficMirrorFilterId = &v - return s -} - -// Describes the Traffic Mirror rule. -type TrafficMirrorFilterRule struct { - _ struct{} `type:"structure"` - - // The description of the Traffic Mirror rule. - Description *string `locationName:"description" type:"string"` - - // The destination CIDR block assigned to the Traffic Mirror rule. - DestinationCidrBlock *string `locationName:"destinationCidrBlock" type:"string"` - - // The destination port range assigned to the Traffic Mirror rule. - DestinationPortRange *TrafficMirrorPortRange `locationName:"destinationPortRange" type:"structure"` - - // The protocol assigned to the Traffic Mirror rule. - Protocol *int64 `locationName:"protocol" type:"integer"` - - // The action assigned to the Traffic Mirror rule. - RuleAction *string `locationName:"ruleAction" type:"string" enum:"TrafficMirrorRuleAction"` - - // The rule number of the Traffic Mirror rule. - RuleNumber *int64 `locationName:"ruleNumber" type:"integer"` - - // The source CIDR block assigned to the Traffic Mirror rule. - SourceCidrBlock *string `locationName:"sourceCidrBlock" type:"string"` - - // The source port range assigned to the Traffic Mirror rule. - SourcePortRange *TrafficMirrorPortRange `locationName:"sourcePortRange" type:"structure"` - - // The traffic direction assigned to the Traffic Mirror rule. - TrafficDirection *string `locationName:"trafficDirection" type:"string" enum:"TrafficDirection"` - - // The ID of the Traffic Mirror filter that the rule is associated with. - TrafficMirrorFilterId *string `locationName:"trafficMirrorFilterId" type:"string"` - - // The ID of the Traffic Mirror rule. - TrafficMirrorFilterRuleId *string `locationName:"trafficMirrorFilterRuleId" type:"string"` -} - -// String returns the string representation -func (s TrafficMirrorFilterRule) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorFilterRule) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *TrafficMirrorFilterRule) SetDescription(v string) *TrafficMirrorFilterRule { - s.Description = &v - return s -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *TrafficMirrorFilterRule) SetDestinationCidrBlock(v string) *TrafficMirrorFilterRule { - s.DestinationCidrBlock = &v - return s -} - -// SetDestinationPortRange sets the DestinationPortRange field's value. -func (s *TrafficMirrorFilterRule) SetDestinationPortRange(v *TrafficMirrorPortRange) *TrafficMirrorFilterRule { - s.DestinationPortRange = v - return s -} - -// SetProtocol sets the Protocol field's value. -func (s *TrafficMirrorFilterRule) SetProtocol(v int64) *TrafficMirrorFilterRule { - s.Protocol = &v - return s -} - -// SetRuleAction sets the RuleAction field's value. -func (s *TrafficMirrorFilterRule) SetRuleAction(v string) *TrafficMirrorFilterRule { - s.RuleAction = &v - return s -} - -// SetRuleNumber sets the RuleNumber field's value. -func (s *TrafficMirrorFilterRule) SetRuleNumber(v int64) *TrafficMirrorFilterRule { - s.RuleNumber = &v - return s -} - -// SetSourceCidrBlock sets the SourceCidrBlock field's value. -func (s *TrafficMirrorFilterRule) SetSourceCidrBlock(v string) *TrafficMirrorFilterRule { - s.SourceCidrBlock = &v - return s -} - -// SetSourcePortRange sets the SourcePortRange field's value. -func (s *TrafficMirrorFilterRule) SetSourcePortRange(v *TrafficMirrorPortRange) *TrafficMirrorFilterRule { - s.SourcePortRange = v - return s -} - -// SetTrafficDirection sets the TrafficDirection field's value. -func (s *TrafficMirrorFilterRule) SetTrafficDirection(v string) *TrafficMirrorFilterRule { - s.TrafficDirection = &v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *TrafficMirrorFilterRule) SetTrafficMirrorFilterId(v string) *TrafficMirrorFilterRule { - s.TrafficMirrorFilterId = &v - return s -} - -// SetTrafficMirrorFilterRuleId sets the TrafficMirrorFilterRuleId field's value. -func (s *TrafficMirrorFilterRule) SetTrafficMirrorFilterRuleId(v string) *TrafficMirrorFilterRule { - s.TrafficMirrorFilterRuleId = &v - return s -} - -// Describes the Traffic Mirror port range. -type TrafficMirrorPortRange struct { - _ struct{} `type:"structure"` - - // The start of the Traffic Mirror port range. This applies to the TCP and UDP - // protocols. - FromPort *int64 `locationName:"fromPort" type:"integer"` - - // The end of the Traffic Mirror port range. This applies to the TCP and UDP - // protocols. - ToPort *int64 `locationName:"toPort" type:"integer"` -} - -// String returns the string representation -func (s TrafficMirrorPortRange) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorPortRange) GoString() string { - return s.String() -} - -// SetFromPort sets the FromPort field's value. -func (s *TrafficMirrorPortRange) SetFromPort(v int64) *TrafficMirrorPortRange { - s.FromPort = &v - return s -} - -// SetToPort sets the ToPort field's value. -func (s *TrafficMirrorPortRange) SetToPort(v int64) *TrafficMirrorPortRange { - s.ToPort = &v - return s -} - -// Information about the Traffic Mirror filter rule port range. -type TrafficMirrorPortRangeRequest struct { - _ struct{} `type:"structure"` - - // The first port in the Traffic Mirror port range. This applies to the TCP - // and UDP protocols. - FromPort *int64 `type:"integer"` - - // The last port in the Traffic Mirror port range. This applies to the TCP and - // UDP protocols. - ToPort *int64 `type:"integer"` -} - -// String returns the string representation -func (s TrafficMirrorPortRangeRequest) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorPortRangeRequest) GoString() string { - return s.String() -} - -// SetFromPort sets the FromPort field's value. -func (s *TrafficMirrorPortRangeRequest) SetFromPort(v int64) *TrafficMirrorPortRangeRequest { - s.FromPort = &v - return s -} - -// SetToPort sets the ToPort field's value. -func (s *TrafficMirrorPortRangeRequest) SetToPort(v int64) *TrafficMirrorPortRangeRequest { - s.ToPort = &v - return s -} - -// Describes a Traffic Mirror session. -type TrafficMirrorSession struct { - _ struct{} `type:"structure"` - - // The description of the Traffic Mirror session. - Description *string `locationName:"description" type:"string"` - - // The ID of the Traffic Mirror session's network interface. - NetworkInterfaceId *string `locationName:"networkInterfaceId" type:"string"` - - // The ID of the account that owns the Traffic Mirror session. - OwnerId *string `locationName:"ownerId" type:"string"` - - // The number of bytes in each packet to mirror. These are the bytes after the - // VXLAN header. To mirror a subset, set this to the length (in bytes) to mirror. - // For example, if you set this value to 100, then the first 100 bytes that - // meet the filter criteria are copied to the target. Do not specify this parameter - // when you want to mirror the entire packet - PacketLength *int64 `locationName:"packetLength" type:"integer"` - - // The session number determines the order in which sessions are evaluated when - // an interface is used by multiple sessions. The first session with a matching - // filter is the one that mirrors the packets. - // - // Valid values are 1-32766. - SessionNumber *int64 `locationName:"sessionNumber" type:"integer"` - - // The tags assigned to the Traffic Mirror session. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the Traffic Mirror filter. - TrafficMirrorFilterId *string `locationName:"trafficMirrorFilterId" type:"string"` - - // The ID for the Traffic Mirror session. - TrafficMirrorSessionId *string `locationName:"trafficMirrorSessionId" type:"string"` - - // The ID of the Traffic Mirror target. - TrafficMirrorTargetId *string `locationName:"trafficMirrorTargetId" type:"string"` - - // The virtual network ID associated with the Traffic Mirror session. - VirtualNetworkId *int64 `locationName:"virtualNetworkId" type:"integer"` -} - -// String returns the string representation -func (s TrafficMirrorSession) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorSession) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *TrafficMirrorSession) SetDescription(v string) *TrafficMirrorSession { - s.Description = &v - return s -} - -// SetNetworkInterfaceId sets the NetworkInterfaceId field's value. -func (s *TrafficMirrorSession) SetNetworkInterfaceId(v string) *TrafficMirrorSession { - s.NetworkInterfaceId = &v - return s -} - -// SetOwnerId sets the OwnerId field's value. -func (s *TrafficMirrorSession) SetOwnerId(v string) *TrafficMirrorSession { - s.OwnerId = &v - return s -} - -// SetPacketLength sets the PacketLength field's value. -func (s *TrafficMirrorSession) SetPacketLength(v int64) *TrafficMirrorSession { - s.PacketLength = &v - return s -} - -// SetSessionNumber sets the SessionNumber field's value. -func (s *TrafficMirrorSession) SetSessionNumber(v int64) *TrafficMirrorSession { - s.SessionNumber = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TrafficMirrorSession) SetTags(v []*Tag) *TrafficMirrorSession { - s.Tags = v - return s -} - -// SetTrafficMirrorFilterId sets the TrafficMirrorFilterId field's value. -func (s *TrafficMirrorSession) SetTrafficMirrorFilterId(v string) *TrafficMirrorSession { - s.TrafficMirrorFilterId = &v - return s -} - -// SetTrafficMirrorSessionId sets the TrafficMirrorSessionId field's value. -func (s *TrafficMirrorSession) SetTrafficMirrorSessionId(v string) *TrafficMirrorSession { - s.TrafficMirrorSessionId = &v - return s -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *TrafficMirrorSession) SetTrafficMirrorTargetId(v string) *TrafficMirrorSession { - s.TrafficMirrorTargetId = &v - return s -} - -// SetVirtualNetworkId sets the VirtualNetworkId field's value. -func (s *TrafficMirrorSession) SetVirtualNetworkId(v int64) *TrafficMirrorSession { - s.VirtualNetworkId = &v - return s -} - -// Describes a Traffic Mirror target. -type TrafficMirrorTarget struct { - _ struct{} `type:"structure"` - - // Information about the Traffic Mirror target. - Description *string `locationName:"description" type:"string"` - - // The network interface ID that is attached to the target. - NetworkInterfaceId *string `locationName:"networkInterfaceId" type:"string"` - - // The Amazon Resource Name (ARN) of the Network Load Balancer. - NetworkLoadBalancerArn *string `locationName:"networkLoadBalancerArn" type:"string"` - - // The ID of the account that owns the Traffic Mirror target. - OwnerId *string `locationName:"ownerId" type:"string"` - - // The tags assigned to the Traffic Mirror target. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the Traffic Mirror target. - TrafficMirrorTargetId *string `locationName:"trafficMirrorTargetId" type:"string"` - - // The type of Traffic Mirror target. - Type *string `locationName:"type" type:"string" enum:"TrafficMirrorTargetType"` -} - -// String returns the string representation -func (s TrafficMirrorTarget) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TrafficMirrorTarget) GoString() string { - return s.String() -} - -// SetDescription sets the Description field's value. -func (s *TrafficMirrorTarget) SetDescription(v string) *TrafficMirrorTarget { - s.Description = &v - return s -} - -// SetNetworkInterfaceId sets the NetworkInterfaceId field's value. -func (s *TrafficMirrorTarget) SetNetworkInterfaceId(v string) *TrafficMirrorTarget { - s.NetworkInterfaceId = &v - return s -} - -// SetNetworkLoadBalancerArn sets the NetworkLoadBalancerArn field's value. -func (s *TrafficMirrorTarget) SetNetworkLoadBalancerArn(v string) *TrafficMirrorTarget { - s.NetworkLoadBalancerArn = &v - return s -} - -// SetOwnerId sets the OwnerId field's value. -func (s *TrafficMirrorTarget) SetOwnerId(v string) *TrafficMirrorTarget { - s.OwnerId = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TrafficMirrorTarget) SetTags(v []*Tag) *TrafficMirrorTarget { - s.Tags = v - return s -} - -// SetTrafficMirrorTargetId sets the TrafficMirrorTargetId field's value. -func (s *TrafficMirrorTarget) SetTrafficMirrorTargetId(v string) *TrafficMirrorTarget { - s.TrafficMirrorTargetId = &v - return s -} - -// SetType sets the Type field's value. -func (s *TrafficMirrorTarget) SetType(v string) *TrafficMirrorTarget { - s.Type = &v - return s -} - -// Describes a transit gateway. -type TransitGateway struct { - _ struct{} `type:"structure"` - - // The creation time. - CreationTime *time.Time `locationName:"creationTime" type:"timestamp"` - - // The description of the transit gateway. - Description *string `locationName:"description" type:"string"` - - // The transit gateway options. - Options *TransitGatewayOptions `locationName:"options" type:"structure"` - - // The ID of the AWS account ID that owns the transit gateway. - OwnerId *string `locationName:"ownerId" type:"string"` - - // The state of the transit gateway. - State *string `locationName:"state" type:"string" enum:"TransitGatewayState"` - - // The tags for the transit gateway. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The Amazon Resource Name (ARN) of the transit gateway. - TransitGatewayArn *string `locationName:"transitGatewayArn" type:"string"` - - // The ID of the transit gateway. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` -} - -// String returns the string representation -func (s TransitGateway) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGateway) GoString() string { - return s.String() -} - -// SetCreationTime sets the CreationTime field's value. -func (s *TransitGateway) SetCreationTime(v time.Time) *TransitGateway { - s.CreationTime = &v - return s -} - -// SetDescription sets the Description field's value. -func (s *TransitGateway) SetDescription(v string) *TransitGateway { - s.Description = &v - return s -} - -// SetOptions sets the Options field's value. -func (s *TransitGateway) SetOptions(v *TransitGatewayOptions) *TransitGateway { - s.Options = v - return s -} - -// SetOwnerId sets the OwnerId field's value. -func (s *TransitGateway) SetOwnerId(v string) *TransitGateway { - s.OwnerId = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGateway) SetState(v string) *TransitGateway { - s.State = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TransitGateway) SetTags(v []*Tag) *TransitGateway { - s.Tags = v - return s -} - -// SetTransitGatewayArn sets the TransitGatewayArn field's value. -func (s *TransitGateway) SetTransitGatewayArn(v string) *TransitGateway { - s.TransitGatewayArn = &v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *TransitGateway) SetTransitGatewayId(v string) *TransitGateway { - s.TransitGatewayId = &v - return s -} - -// Describes an association between a resource attachment and a transit gateway -// route table. -type TransitGatewayAssociation struct { - _ struct{} `type:"structure"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The resource type. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The state of the association. - State *string `locationName:"state" type:"string" enum:"TransitGatewayAssociationState"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` - - // The ID of the transit gateway route table. - TransitGatewayRouteTableId *string `locationName:"transitGatewayRouteTableId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayAssociation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayAssociation) GoString() string { - return s.String() -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayAssociation) SetResourceId(v string) *TransitGatewayAssociation { - s.ResourceId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayAssociation) SetResourceType(v string) *TransitGatewayAssociation { - s.ResourceType = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayAssociation) SetState(v string) *TransitGatewayAssociation { - s.State = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayAssociation) SetTransitGatewayAttachmentId(v string) *TransitGatewayAssociation { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *TransitGatewayAssociation) SetTransitGatewayRouteTableId(v string) *TransitGatewayAssociation { - s.TransitGatewayRouteTableId = &v - return s -} - -// Describes an attachment between a resource and a transit gateway. -type TransitGatewayAttachment struct { - _ struct{} `type:"structure"` - - // The association. - Association *TransitGatewayAttachmentAssociation `locationName:"association" type:"structure"` - - // The creation time. - CreationTime *time.Time `locationName:"creationTime" type:"timestamp"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The ID of the AWS account that owns the resource. - ResourceOwnerId *string `locationName:"resourceOwnerId" type:"string"` - - // The resource type. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The attachment state. - State *string `locationName:"state" type:"string" enum:"TransitGatewayAttachmentState"` - - // The tags for the attachment. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` - - // The ID of the transit gateway. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` - - // The ID of the AWS account that owns the transit gateway. - TransitGatewayOwnerId *string `locationName:"transitGatewayOwnerId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayAttachment) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayAttachment) GoString() string { - return s.String() -} - -// SetAssociation sets the Association field's value. -func (s *TransitGatewayAttachment) SetAssociation(v *TransitGatewayAttachmentAssociation) *TransitGatewayAttachment { - s.Association = v - return s -} - -// SetCreationTime sets the CreationTime field's value. -func (s *TransitGatewayAttachment) SetCreationTime(v time.Time) *TransitGatewayAttachment { - s.CreationTime = &v - return s -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayAttachment) SetResourceId(v string) *TransitGatewayAttachment { - s.ResourceId = &v - return s -} - -// SetResourceOwnerId sets the ResourceOwnerId field's value. -func (s *TransitGatewayAttachment) SetResourceOwnerId(v string) *TransitGatewayAttachment { - s.ResourceOwnerId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayAttachment) SetResourceType(v string) *TransitGatewayAttachment { - s.ResourceType = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayAttachment) SetState(v string) *TransitGatewayAttachment { - s.State = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TransitGatewayAttachment) SetTags(v []*Tag) *TransitGatewayAttachment { - s.Tags = v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayAttachment) SetTransitGatewayAttachmentId(v string) *TransitGatewayAttachment { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *TransitGatewayAttachment) SetTransitGatewayId(v string) *TransitGatewayAttachment { - s.TransitGatewayId = &v - return s -} - -// SetTransitGatewayOwnerId sets the TransitGatewayOwnerId field's value. -func (s *TransitGatewayAttachment) SetTransitGatewayOwnerId(v string) *TransitGatewayAttachment { - s.TransitGatewayOwnerId = &v - return s -} - -// Describes an association. -type TransitGatewayAttachmentAssociation struct { - _ struct{} `type:"structure"` - - // The state of the association. - State *string `locationName:"state" type:"string" enum:"TransitGatewayAssociationState"` - - // The ID of the route table for the transit gateway. - TransitGatewayRouteTableId *string `locationName:"transitGatewayRouteTableId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayAttachmentAssociation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayAttachmentAssociation) GoString() string { - return s.String() -} - -// SetState sets the State field's value. -func (s *TransitGatewayAttachmentAssociation) SetState(v string) *TransitGatewayAttachmentAssociation { - s.State = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *TransitGatewayAttachmentAssociation) SetTransitGatewayRouteTableId(v string) *TransitGatewayAttachmentAssociation { - s.TransitGatewayRouteTableId = &v - return s -} - -// Describes a propagation route table. -type TransitGatewayAttachmentPropagation struct { - _ struct{} `type:"structure"` - - // The state of the propagation route table. - State *string `locationName:"state" type:"string" enum:"TransitGatewayPropagationState"` - - // The ID of the propagation route table. - TransitGatewayRouteTableId *string `locationName:"transitGatewayRouteTableId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayAttachmentPropagation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayAttachmentPropagation) GoString() string { - return s.String() -} - -// SetState sets the State field's value. -func (s *TransitGatewayAttachmentPropagation) SetState(v string) *TransitGatewayAttachmentPropagation { - s.State = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *TransitGatewayAttachmentPropagation) SetTransitGatewayRouteTableId(v string) *TransitGatewayAttachmentPropagation { - s.TransitGatewayRouteTableId = &v - return s -} - -// Describes the options for a transit gateway. -type TransitGatewayOptions struct { - _ struct{} `type:"structure"` - - // A private Autonomous System Number (ASN) for the Amazon side of a BGP session. - // The range is 64512 to 65534 for 16-bit ASNs and 4200000000 to 4294967294 - // for 32-bit ASNs. - AmazonSideAsn *int64 `locationName:"amazonSideAsn" type:"long"` - - // The ID of the default association route table. - AssociationDefaultRouteTableId *string `locationName:"associationDefaultRouteTableId" type:"string"` - - // Indicates whether attachment requests are automatically accepted. - AutoAcceptSharedAttachments *string `locationName:"autoAcceptSharedAttachments" type:"string" enum:"AutoAcceptSharedAttachmentsValue"` - - // Indicates whether resource attachments are automatically associated with - // the default association route table. - DefaultRouteTableAssociation *string `locationName:"defaultRouteTableAssociation" type:"string" enum:"DefaultRouteTableAssociationValue"` - - // Indicates whether resource attachments automatically propagate routes to - // the default propagation route table. - DefaultRouteTablePropagation *string `locationName:"defaultRouteTablePropagation" type:"string" enum:"DefaultRouteTablePropagationValue"` - - // Indicates whether DNS support is enabled. - DnsSupport *string `locationName:"dnsSupport" type:"string" enum:"DnsSupportValue"` - - // The ID of the default propagation route table. - PropagationDefaultRouteTableId *string `locationName:"propagationDefaultRouteTableId" type:"string"` - - // Indicates whether Equal Cost Multipath Protocol support is enabled. - VpnEcmpSupport *string `locationName:"vpnEcmpSupport" type:"string" enum:"VpnEcmpSupportValue"` -} - -// String returns the string representation -func (s TransitGatewayOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayOptions) GoString() string { - return s.String() -} - -// SetAmazonSideAsn sets the AmazonSideAsn field's value. -func (s *TransitGatewayOptions) SetAmazonSideAsn(v int64) *TransitGatewayOptions { - s.AmazonSideAsn = &v - return s -} - -// SetAssociationDefaultRouteTableId sets the AssociationDefaultRouteTableId field's value. -func (s *TransitGatewayOptions) SetAssociationDefaultRouteTableId(v string) *TransitGatewayOptions { - s.AssociationDefaultRouteTableId = &v - return s -} - -// SetAutoAcceptSharedAttachments sets the AutoAcceptSharedAttachments field's value. -func (s *TransitGatewayOptions) SetAutoAcceptSharedAttachments(v string) *TransitGatewayOptions { - s.AutoAcceptSharedAttachments = &v - return s -} - -// SetDefaultRouteTableAssociation sets the DefaultRouteTableAssociation field's value. -func (s *TransitGatewayOptions) SetDefaultRouteTableAssociation(v string) *TransitGatewayOptions { - s.DefaultRouteTableAssociation = &v - return s -} - -// SetDefaultRouteTablePropagation sets the DefaultRouteTablePropagation field's value. -func (s *TransitGatewayOptions) SetDefaultRouteTablePropagation(v string) *TransitGatewayOptions { - s.DefaultRouteTablePropagation = &v - return s -} - -// SetDnsSupport sets the DnsSupport field's value. -func (s *TransitGatewayOptions) SetDnsSupport(v string) *TransitGatewayOptions { - s.DnsSupport = &v - return s -} - -// SetPropagationDefaultRouteTableId sets the PropagationDefaultRouteTableId field's value. -func (s *TransitGatewayOptions) SetPropagationDefaultRouteTableId(v string) *TransitGatewayOptions { - s.PropagationDefaultRouteTableId = &v - return s -} - -// SetVpnEcmpSupport sets the VpnEcmpSupport field's value. -func (s *TransitGatewayOptions) SetVpnEcmpSupport(v string) *TransitGatewayOptions { - s.VpnEcmpSupport = &v - return s -} - -// Describes route propagation. -type TransitGatewayPropagation struct { - _ struct{} `type:"structure"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The resource type. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The state. - State *string `locationName:"state" type:"string" enum:"TransitGatewayPropagationState"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` - - // The ID of the transit gateway route table. - TransitGatewayRouteTableId *string `locationName:"transitGatewayRouteTableId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayPropagation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayPropagation) GoString() string { - return s.String() -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayPropagation) SetResourceId(v string) *TransitGatewayPropagation { - s.ResourceId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayPropagation) SetResourceType(v string) *TransitGatewayPropagation { - s.ResourceType = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayPropagation) SetState(v string) *TransitGatewayPropagation { - s.State = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayPropagation) SetTransitGatewayAttachmentId(v string) *TransitGatewayPropagation { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *TransitGatewayPropagation) SetTransitGatewayRouteTableId(v string) *TransitGatewayPropagation { - s.TransitGatewayRouteTableId = &v - return s -} - -// Describes the options for a transit gateway. -type TransitGatewayRequestOptions struct { - _ struct{} `type:"structure"` - - // A private Autonomous System Number (ASN) for the Amazon side of a BGP session. - // The range is 64512 to 65534 for 16-bit ASNs and 4200000000 to 4294967294 - // for 32-bit ASNs. - AmazonSideAsn *int64 `type:"long"` - - // Enable or disable automatic acceptance of attachment requests. The default - // is disable. - AutoAcceptSharedAttachments *string `type:"string" enum:"AutoAcceptSharedAttachmentsValue"` - - // Enable or disable automatic association with the default association route - // table. The default is enable. - DefaultRouteTableAssociation *string `type:"string" enum:"DefaultRouteTableAssociationValue"` - - // Enable or disable automatic propagation of routes to the default propagation - // route table. The default is enable. - DefaultRouteTablePropagation *string `type:"string" enum:"DefaultRouteTablePropagationValue"` - - // Enable or disable DNS support. - DnsSupport *string `type:"string" enum:"DnsSupportValue"` - - // Enable or disable Equal Cost Multipath Protocol support. - VpnEcmpSupport *string `type:"string" enum:"VpnEcmpSupportValue"` -} - -// String returns the string representation -func (s TransitGatewayRequestOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRequestOptions) GoString() string { - return s.String() -} - -// SetAmazonSideAsn sets the AmazonSideAsn field's value. -func (s *TransitGatewayRequestOptions) SetAmazonSideAsn(v int64) *TransitGatewayRequestOptions { - s.AmazonSideAsn = &v - return s -} - -// SetAutoAcceptSharedAttachments sets the AutoAcceptSharedAttachments field's value. -func (s *TransitGatewayRequestOptions) SetAutoAcceptSharedAttachments(v string) *TransitGatewayRequestOptions { - s.AutoAcceptSharedAttachments = &v - return s -} - -// SetDefaultRouteTableAssociation sets the DefaultRouteTableAssociation field's value. -func (s *TransitGatewayRequestOptions) SetDefaultRouteTableAssociation(v string) *TransitGatewayRequestOptions { - s.DefaultRouteTableAssociation = &v - return s -} - -// SetDefaultRouteTablePropagation sets the DefaultRouteTablePropagation field's value. -func (s *TransitGatewayRequestOptions) SetDefaultRouteTablePropagation(v string) *TransitGatewayRequestOptions { - s.DefaultRouteTablePropagation = &v - return s -} - -// SetDnsSupport sets the DnsSupport field's value. -func (s *TransitGatewayRequestOptions) SetDnsSupport(v string) *TransitGatewayRequestOptions { - s.DnsSupport = &v - return s -} - -// SetVpnEcmpSupport sets the VpnEcmpSupport field's value. -func (s *TransitGatewayRequestOptions) SetVpnEcmpSupport(v string) *TransitGatewayRequestOptions { - s.VpnEcmpSupport = &v - return s -} - -// Describes a route for a transit gateway route table. -type TransitGatewayRoute struct { - _ struct{} `type:"structure"` - - // The CIDR block used for destination matches. - DestinationCidrBlock *string `locationName:"destinationCidrBlock" type:"string"` - - // The state of the route. - State *string `locationName:"state" type:"string" enum:"TransitGatewayRouteState"` - - // The attachments. - TransitGatewayAttachments []*TransitGatewayRouteAttachment `locationName:"transitGatewayAttachments" locationNameList:"item" type:"list"` - - // The route type. - Type *string `locationName:"type" type:"string" enum:"TransitGatewayRouteType"` -} - -// String returns the string representation -func (s TransitGatewayRoute) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRoute) GoString() string { - return s.String() -} - -// SetDestinationCidrBlock sets the DestinationCidrBlock field's value. -func (s *TransitGatewayRoute) SetDestinationCidrBlock(v string) *TransitGatewayRoute { - s.DestinationCidrBlock = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayRoute) SetState(v string) *TransitGatewayRoute { - s.State = &v - return s -} - -// SetTransitGatewayAttachments sets the TransitGatewayAttachments field's value. -func (s *TransitGatewayRoute) SetTransitGatewayAttachments(v []*TransitGatewayRouteAttachment) *TransitGatewayRoute { - s.TransitGatewayAttachments = v - return s -} - -// SetType sets the Type field's value. -func (s *TransitGatewayRoute) SetType(v string) *TransitGatewayRoute { - s.Type = &v - return s -} - -// Describes a route attachment. -type TransitGatewayRouteAttachment struct { - _ struct{} `type:"structure"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The resource type. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayRouteAttachment) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRouteAttachment) GoString() string { - return s.String() -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayRouteAttachment) SetResourceId(v string) *TransitGatewayRouteAttachment { - s.ResourceId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayRouteAttachment) SetResourceType(v string) *TransitGatewayRouteAttachment { - s.ResourceType = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayRouteAttachment) SetTransitGatewayAttachmentId(v string) *TransitGatewayRouteAttachment { - s.TransitGatewayAttachmentId = &v - return s -} - -// Describes a transit gateway route table. -type TransitGatewayRouteTable struct { - _ struct{} `type:"structure"` - - // The creation time. - CreationTime *time.Time `locationName:"creationTime" type:"timestamp"` - - // Indicates whether this is the default association route table for the transit - // gateway. - DefaultAssociationRouteTable *bool `locationName:"defaultAssociationRouteTable" type:"boolean"` - - // Indicates whether this is the default propagation route table for the transit - // gateway. - DefaultPropagationRouteTable *bool `locationName:"defaultPropagationRouteTable" type:"boolean"` - - // The state of the transit gateway route table. - State *string `locationName:"state" type:"string" enum:"TransitGatewayRouteTableState"` - - // Any tags assigned to the route table. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the transit gateway. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` - - // The ID of the transit gateway route table. - TransitGatewayRouteTableId *string `locationName:"transitGatewayRouteTableId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayRouteTable) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRouteTable) GoString() string { - return s.String() -} - -// SetCreationTime sets the CreationTime field's value. -func (s *TransitGatewayRouteTable) SetCreationTime(v time.Time) *TransitGatewayRouteTable { - s.CreationTime = &v - return s -} - -// SetDefaultAssociationRouteTable sets the DefaultAssociationRouteTable field's value. -func (s *TransitGatewayRouteTable) SetDefaultAssociationRouteTable(v bool) *TransitGatewayRouteTable { - s.DefaultAssociationRouteTable = &v - return s -} - -// SetDefaultPropagationRouteTable sets the DefaultPropagationRouteTable field's value. -func (s *TransitGatewayRouteTable) SetDefaultPropagationRouteTable(v bool) *TransitGatewayRouteTable { - s.DefaultPropagationRouteTable = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayRouteTable) SetState(v string) *TransitGatewayRouteTable { - s.State = &v - return s -} - -// SetTags sets the Tags field's value. -func (s *TransitGatewayRouteTable) SetTags(v []*Tag) *TransitGatewayRouteTable { - s.Tags = v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *TransitGatewayRouteTable) SetTransitGatewayId(v string) *TransitGatewayRouteTable { - s.TransitGatewayId = &v - return s -} - -// SetTransitGatewayRouteTableId sets the TransitGatewayRouteTableId field's value. -func (s *TransitGatewayRouteTable) SetTransitGatewayRouteTableId(v string) *TransitGatewayRouteTable { - s.TransitGatewayRouteTableId = &v - return s -} - -// Describes an association between a route table and a resource attachment. -type TransitGatewayRouteTableAssociation struct { - _ struct{} `type:"structure"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The resource type. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The state of the association. - State *string `locationName:"state" type:"string" enum:"TransitGatewayAssociationState"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayRouteTableAssociation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRouteTableAssociation) GoString() string { - return s.String() -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayRouteTableAssociation) SetResourceId(v string) *TransitGatewayRouteTableAssociation { - s.ResourceId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayRouteTableAssociation) SetResourceType(v string) *TransitGatewayRouteTableAssociation { - s.ResourceType = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayRouteTableAssociation) SetState(v string) *TransitGatewayRouteTableAssociation { - s.State = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayRouteTableAssociation) SetTransitGatewayAttachmentId(v string) *TransitGatewayRouteTableAssociation { - s.TransitGatewayAttachmentId = &v - return s -} - -// Describes a route table propagation. -type TransitGatewayRouteTablePropagation struct { - _ struct{} `type:"structure"` - - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` - - // The type of resource. - ResourceType *string `locationName:"resourceType" type:"string" enum:"TransitGatewayAttachmentResourceType"` - - // The state of the resource. - State *string `locationName:"state" type:"string" enum:"TransitGatewayPropagationState"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayRouteTablePropagation) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayRouteTablePropagation) GoString() string { - return s.String() -} - -// SetResourceId sets the ResourceId field's value. -func (s *TransitGatewayRouteTablePropagation) SetResourceId(v string) *TransitGatewayRouteTablePropagation { - s.ResourceId = &v - return s -} - -// SetResourceType sets the ResourceType field's value. -func (s *TransitGatewayRouteTablePropagation) SetResourceType(v string) *TransitGatewayRouteTablePropagation { - s.ResourceType = &v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayRouteTablePropagation) SetState(v string) *TransitGatewayRouteTablePropagation { - s.State = &v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayRouteTablePropagation) SetTransitGatewayAttachmentId(v string) *TransitGatewayRouteTablePropagation { - s.TransitGatewayAttachmentId = &v - return s -} - -// Describes a VPC attachment. -type TransitGatewayVpcAttachment struct { - _ struct{} `type:"structure"` - - // The creation time. - CreationTime *time.Time `locationName:"creationTime" type:"timestamp"` - - // The VPC attachment options. - Options *TransitGatewayVpcAttachmentOptions `locationName:"options" type:"structure"` - - // The state of the VPC attachment. - State *string `locationName:"state" type:"string" enum:"TransitGatewayAttachmentState"` - - // The IDs of the subnets. - SubnetIds []*string `locationName:"subnetIds" locationNameList:"item" type:"list"` - - // The tags for the VPC attachment. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - - // The ID of the attachment. - TransitGatewayAttachmentId *string `locationName:"transitGatewayAttachmentId" type:"string"` - - // The ID of the transit gateway. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` - - // The ID of the VPC. - VpcId *string `locationName:"vpcId" type:"string"` - - // The ID of the AWS account that owns the VPC. - VpcOwnerId *string `locationName:"vpcOwnerId" type:"string"` -} - -// String returns the string representation -func (s TransitGatewayVpcAttachment) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayVpcAttachment) GoString() string { - return s.String() -} - -// SetCreationTime sets the CreationTime field's value. -func (s *TransitGatewayVpcAttachment) SetCreationTime(v time.Time) *TransitGatewayVpcAttachment { - s.CreationTime = &v - return s -} - -// SetOptions sets the Options field's value. -func (s *TransitGatewayVpcAttachment) SetOptions(v *TransitGatewayVpcAttachmentOptions) *TransitGatewayVpcAttachment { - s.Options = v - return s -} - -// SetState sets the State field's value. -func (s *TransitGatewayVpcAttachment) SetState(v string) *TransitGatewayVpcAttachment { - s.State = &v - return s -} - -// SetSubnetIds sets the SubnetIds field's value. -func (s *TransitGatewayVpcAttachment) SetSubnetIds(v []*string) *TransitGatewayVpcAttachment { - s.SubnetIds = v - return s -} - -// SetTags sets the Tags field's value. -func (s *TransitGatewayVpcAttachment) SetTags(v []*Tag) *TransitGatewayVpcAttachment { - s.Tags = v - return s -} - -// SetTransitGatewayAttachmentId sets the TransitGatewayAttachmentId field's value. -func (s *TransitGatewayVpcAttachment) SetTransitGatewayAttachmentId(v string) *TransitGatewayVpcAttachment { - s.TransitGatewayAttachmentId = &v - return s -} - -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *TransitGatewayVpcAttachment) SetTransitGatewayId(v string) *TransitGatewayVpcAttachment { - s.TransitGatewayId = &v - return s -} - -// SetVpcId sets the VpcId field's value. -func (s *TransitGatewayVpcAttachment) SetVpcId(v string) *TransitGatewayVpcAttachment { - s.VpcId = &v - return s -} - -// SetVpcOwnerId sets the VpcOwnerId field's value. -func (s *TransitGatewayVpcAttachment) SetVpcOwnerId(v string) *TransitGatewayVpcAttachment { - s.VpcOwnerId = &v - return s -} - -// Describes the VPC attachment options. -type TransitGatewayVpcAttachmentOptions struct { - _ struct{} `type:"structure"` - - // Indicates whether DNS support is enabled. - DnsSupport *string `locationName:"dnsSupport" type:"string" enum:"DnsSupportValue"` - - // Indicates whether IPv6 support is enabled. - Ipv6Support *string `locationName:"ipv6Support" type:"string" enum:"Ipv6SupportValue"` -} - -// String returns the string representation -func (s TransitGatewayVpcAttachmentOptions) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s TransitGatewayVpcAttachmentOptions) GoString() string { - return s.String() -} - -// SetDnsSupport sets the DnsSupport field's value. -func (s *TransitGatewayVpcAttachmentOptions) SetDnsSupport(v string) *TransitGatewayVpcAttachmentOptions { - s.DnsSupport = &v - return s -} - -// SetIpv6Support sets the Ipv6Support field's value. -func (s *TransitGatewayVpcAttachmentOptions) SetIpv6Support(v string) *TransitGatewayVpcAttachmentOptions { - s.Ipv6Support = &v - return s -} - type UnassignIpv6AddressesInput struct { _ struct{} `type:"structure"` @@ -90303,6 +67721,7 @@ func (s UnassignPrivateIpAddressesOutput) GoString() string { return s.String() } +// Contains the parameters for UnmonitorInstances. type UnmonitorInstancesInput struct { _ struct{} `type:"structure"` @@ -90312,7 +67731,7 @@ type UnmonitorInstancesInput struct { // it is UnauthorizedOperation. DryRun *bool `locationName:"dryRun" type:"boolean"` - // The IDs of the instances. + // One or more instance IDs. // // InstanceIds is a required field InstanceIds []*string `locationName:"InstanceId" locationNameList:"InstanceId" type:"list" required:"true"` @@ -90353,6 +67772,7 @@ func (s *UnmonitorInstancesInput) SetInstanceIds(v []*string) *UnmonitorInstance return s } +// Contains the output of UnmonitorInstances. type UnmonitorInstancesOutput struct { _ struct{} `type:"structure"` @@ -90376,13 +67796,12 @@ func (s *UnmonitorInstancesOutput) SetInstanceMonitorings(v []*InstanceMonitorin return s } -// Describes the T2 or T3 instance whose credit option for CPU usage was not -// modified. +// Describes the T2 instance whose credit option for CPU usage was not modified. type UnsuccessfulInstanceCreditSpecificationItem struct { _ struct{} `type:"structure"` - // The applicable error for the T2 or T3 instance whose credit option for CPU - // usage was not modified. + // The applicable error for the T2 instance whose credit option for CPU usage + // was not modified. Error *UnsuccessfulInstanceCreditSpecificationItemError `locationName:"error" type:"structure"` // The ID of the instance. @@ -90411,8 +67830,8 @@ func (s *UnsuccessfulInstanceCreditSpecificationItem) SetInstanceId(v string) *U return s } -// Information about the error for the T2 or T3 instance whose credit option -// for CPU usage was not modified. +// Information about the error for the T2 instance whose credit option for CPU +// usage was not modified. type UnsuccessfulInstanceCreditSpecificationItemError struct { _ struct{} `type:"structure"` @@ -90450,7 +67869,9 @@ type UnsuccessfulItem struct { _ struct{} `type:"structure"` // Information about the error. - Error *UnsuccessfulItemError `locationName:"error" type:"structure"` + // + // Error is a required field + Error *UnsuccessfulItemError `locationName:"error" type:"structure" required:"true"` // The ID of the resource. ResourceId *string `locationName:"resourceId" type:"string"` @@ -90479,15 +67900,19 @@ func (s *UnsuccessfulItem) SetResourceId(v string) *UnsuccessfulItem { } // Information about the error that occurred. For more information about errors, -// see Error Codes (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html). +// see Error Codes (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/errors-overview.html). type UnsuccessfulItemError struct { _ struct{} `type:"structure"` // The error code. - Code *string `locationName:"code" type:"string"` + // + // Code is a required field + Code *string `locationName:"code" type:"string" required:"true"` // The error message accompanying the error code. - Message *string `locationName:"message" type:"string"` + // + // Message is a required field + Message *string `locationName:"message" type:"string" required:"true"` } // String returns the string representation @@ -90512,6 +67937,7 @@ func (s *UnsuccessfulItemError) SetMessage(v string) *UnsuccessfulItemError { return s } +// Contains the parameters for UpdateSecurityGroupRuleDescriptionsEgress. type UpdateSecurityGroupRuleDescriptionsEgressInput struct { _ struct{} `type:"structure"` @@ -90583,6 +68009,7 @@ func (s *UpdateSecurityGroupRuleDescriptionsEgressInput) SetIpPermissions(v []*I return s } +// Contains the output of UpdateSecurityGroupRuleDescriptionsEgress. type UpdateSecurityGroupRuleDescriptionsEgressOutput struct { _ struct{} `type:"structure"` @@ -90606,6 +68033,7 @@ func (s *UpdateSecurityGroupRuleDescriptionsEgressOutput) SetReturn(v bool) *Upd return s } +// Contains the parameters for UpdateSecurityGroupRuleDescriptionsIngress. type UpdateSecurityGroupRuleDescriptionsIngressInput struct { _ struct{} `type:"structure"` @@ -90677,6 +68105,7 @@ func (s *UpdateSecurityGroupRuleDescriptionsIngressInput) SetIpPermissions(v []* return s } +// Contains the output of UpdateSecurityGroupRuleDescriptionsIngress. type UpdateSecurityGroupRuleDescriptionsIngressOutput struct { _ struct{} `type:"structure"` @@ -90960,29 +68389,27 @@ type Volume struct { // The time stamp when volume creation was initiated. CreateTime *time.Time `locationName:"createTime" type:"timestamp"` - // Indicates whether the volume is encrypted. + // Indicates whether the volume will be encrypted. Encrypted *bool `locationName:"encrypted" type:"boolean"` // The number of I/O operations per second (IOPS) that the volume supports. // For Provisioned IOPS SSD volumes, this represents the number of IOPS that // are provisioned for the volume. For General Purpose SSD volumes, this represents // the baseline performance of the volume and the rate at which the volume accumulates - // I/O credits for bursting. For more information, see Amazon EBS Volume Types - // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) + // I/O credits for bursting. For more information about General Purpose SSD + // baseline performance, I/O credits, and bursting, see Amazon EBS Volume Types + // (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html) // in the Amazon Elastic Compute Cloud User Guide. // - // Constraints: Range is 100-16,000 IOPS for gp2 volumes and 100 to 64,000IOPS - // for io1 volumes, in most Regions. The maximum IOPS for io1 of 64,000 is guaranteed - // only on Nitro-based instances (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html#ec2-nitro-instances). - // Other instance families guarantee performance up to 32,000 IOPS. + // Constraint: Range is 100-32000 IOPS for io1 volumes and 100-10000 IOPS for + // gp2 volumes. // // Condition: This parameter is required for requests to create io1 volumes; // it is not used in requests to create gp2, st1, sc1, or standard volumes. Iops *int64 `locationName:"iops" type:"integer"` - // The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS KMS) - // customer master key (CMK) that was used to protect the volume encryption - // key for the volume. + // The full ARN of the AWS Key Management Service (AWS KMS) customer master + // key (CMK) that was used to protect the volume encryption key for the volume. KmsKeyId *string `locationName:"kmsKeyId" type:"string"` // The size of the volume, in GiBs. @@ -91582,9 +69009,6 @@ type Vpc struct { // Indicates whether the VPC is the default VPC. IsDefault *bool `locationName:"isDefault" type:"boolean"` - // The ID of the AWS account that owns the VPC. - OwnerId *string `locationName:"ownerId" type:"string"` - // The current state of the VPC. State *string `locationName:"state" type:"string" enum:"VpcState"` @@ -91641,12 +69065,6 @@ func (s *Vpc) SetIsDefault(v bool) *Vpc { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *Vpc) SetOwnerId(v string) *Vpc { - s.OwnerId = &v - return s -} - // SetState sets the State field's value. func (s *Vpc) SetState(v string) *Vpc { s.State = &v @@ -91832,9 +69250,6 @@ type VpcEndpoint struct { // (Interface endpoint) One or more network interfaces for the endpoint. NetworkInterfaceIds []*string `locationName:"networkInterfaceIdSet" locationNameList:"item" type:"list"` - // The ID of the AWS account that owns the VPC endpoint. - OwnerId *string `locationName:"ownerId" type:"string"` - // The policy document associated with the endpoint, if applicable. PolicyDocument *string `locationName:"policyDocument" type:"string"` @@ -91842,9 +69257,6 @@ type VpcEndpoint struct { // hosted zone. PrivateDnsEnabled *bool `locationName:"privateDnsEnabled" type:"boolean"` - // Indicates whether the VPC endpoint is being managed by its service. - RequesterManaged *bool `locationName:"requesterManaged" type:"boolean"` - // (Gateway endpoint) One or more route tables associated with the endpoint. RouteTableIds []*string `locationName:"routeTableIdSet" locationNameList:"item" type:"list"` @@ -91857,9 +69269,6 @@ type VpcEndpoint struct { // (Interface endpoint) One or more subnets in which the endpoint is located. SubnetIds []*string `locationName:"subnetIdSet" locationNameList:"item" type:"list"` - // Any tags assigned to the VPC endpoint. - Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - // The ID of the VPC endpoint. VpcEndpointId *string `locationName:"vpcEndpointId" type:"string"` @@ -91904,12 +69313,6 @@ func (s *VpcEndpoint) SetNetworkInterfaceIds(v []*string) *VpcEndpoint { return s } -// SetOwnerId sets the OwnerId field's value. -func (s *VpcEndpoint) SetOwnerId(v string) *VpcEndpoint { - s.OwnerId = &v - return s -} - // SetPolicyDocument sets the PolicyDocument field's value. func (s *VpcEndpoint) SetPolicyDocument(v string) *VpcEndpoint { s.PolicyDocument = &v @@ -91922,12 +69325,6 @@ func (s *VpcEndpoint) SetPrivateDnsEnabled(v bool) *VpcEndpoint { return s } -// SetRequesterManaged sets the RequesterManaged field's value. -func (s *VpcEndpoint) SetRequesterManaged(v bool) *VpcEndpoint { - s.RequesterManaged = &v - return s -} - // SetRouteTableIds sets the RouteTableIds field's value. func (s *VpcEndpoint) SetRouteTableIds(v []*string) *VpcEndpoint { s.RouteTableIds = v @@ -91952,12 +69349,6 @@ func (s *VpcEndpoint) SetSubnetIds(v []*string) *VpcEndpoint { return s } -// SetTags sets the Tags field's value. -func (s *VpcEndpoint) SetTags(v []*Tag) *VpcEndpoint { - s.Tags = v - return s -} - // SetVpcEndpointId sets the VpcEndpointId field's value. func (s *VpcEndpoint) SetVpcEndpointId(v string) *VpcEndpoint { s.VpcEndpointId = &v @@ -91983,12 +69374,6 @@ type VpcEndpointConnection struct { // The date and time the VPC endpoint was created. CreationTimestamp *time.Time `locationName:"creationTimestamp" type:"timestamp"` - // The DNS entries for the VPC endpoint. - DnsEntries []*DnsEntry `locationName:"dnsEntrySet" locationNameList:"item" type:"list"` - - // The Amazon Resource Names (ARNs) of the network load balancers for the service. - NetworkLoadBalancerArns []*string `locationName:"networkLoadBalancerArnSet" locationNameList:"item" type:"list"` - // The ID of the service to which the endpoint is connected. ServiceId *string `locationName:"serviceId" type:"string"` @@ -92018,18 +69403,6 @@ func (s *VpcEndpointConnection) SetCreationTimestamp(v time.Time) *VpcEndpointCo return s } -// SetDnsEntries sets the DnsEntries field's value. -func (s *VpcEndpointConnection) SetDnsEntries(v []*DnsEntry) *VpcEndpointConnection { - s.DnsEntries = v - return s -} - -// SetNetworkLoadBalancerArns sets the NetworkLoadBalancerArns field's value. -func (s *VpcEndpointConnection) SetNetworkLoadBalancerArns(v []*string) *VpcEndpointConnection { - s.NetworkLoadBalancerArns = v - return s -} - // SetServiceId sets the ServiceId field's value. func (s *VpcEndpointConnection) SetServiceId(v string) *VpcEndpointConnection { s.ServiceId = &v @@ -92265,7 +69638,7 @@ type VpcPeeringConnectionVpcInfo struct { // requester VPC. PeeringOptions *VpcPeeringConnectionOptionsDescription `locationName:"peeringOptions" type:"structure"` - // The Region in which the VPC is located. + // The region in which the VPC is located. Region *string `locationName:"region" type:"string"` // The ID of the VPC. @@ -92329,7 +69702,9 @@ type VpnConnection struct { _ struct{} `type:"structure"` // The category of the VPN connection. A value of VPN indicates an AWS VPN connection. - // A value of VPN-Classic indicates an AWS Classic VPN connection. + // A value of VPN-Classic indicates an AWS Classic VPN connection. For more + // information, see AWS Managed VPN Categories (http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_VPN.html#vpn-categories) + // in the Amazon Virtual Private Cloud User Guide. Category *string `locationName:"category" type:"string"` // The configuration information for the VPN connection's customer gateway (in @@ -92353,9 +69728,6 @@ type VpnConnection struct { // Any tags assigned to the VPN connection. Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` - // The ID of the transit gateway associated with the VPN connection. - TransitGatewayId *string `locationName:"transitGatewayId" type:"string"` - // The type of VPN connection. Type *string `locationName:"type" type:"string" enum:"GatewayType"` @@ -92421,12 +69793,6 @@ func (s *VpnConnection) SetTags(v []*Tag) *VpnConnection { return s } -// SetTransitGatewayId sets the TransitGatewayId field's value. -func (s *VpnConnection) SetTransitGatewayId(v string) *VpnConnection { - s.TransitGatewayId = &v - return s -} - // SetType sets the Type field's value. func (s *VpnConnection) SetType(v string) *VpnConnection { s.Type = &v @@ -92690,79 +70056,6 @@ func (s *VpnTunnelOptionsSpecification) SetTunnelInsideCidr(v string) *VpnTunnel return s } -type WithdrawByoipCidrInput struct { - _ struct{} `type:"structure"` - - // The public IPv4 address range, in CIDR notation. - // - // Cidr is a required field - Cidr *string `type:"string" required:"true"` - - // Checks whether you have the required permissions for the action, without - // actually making the request, and provides an error response. If you have - // the required permissions, the error response is DryRunOperation. Otherwise, - // it is UnauthorizedOperation. - DryRun *bool `type:"boolean"` -} - -// String returns the string representation -func (s WithdrawByoipCidrInput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s WithdrawByoipCidrInput) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *WithdrawByoipCidrInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "WithdrawByoipCidrInput"} - if s.Cidr == nil { - invalidParams.Add(request.NewErrParamRequired("Cidr")) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetCidr sets the Cidr field's value. -func (s *WithdrawByoipCidrInput) SetCidr(v string) *WithdrawByoipCidrInput { - s.Cidr = &v - return s -} - -// SetDryRun sets the DryRun field's value. -func (s *WithdrawByoipCidrInput) SetDryRun(v bool) *WithdrawByoipCidrInput { - s.DryRun = &v - return s -} - -type WithdrawByoipCidrOutput struct { - _ struct{} `type:"structure"` - - // Information about the address pool. - ByoipCidr *ByoipCidr `locationName:"byoipCidr" type:"structure"` -} - -// String returns the string representation -func (s WithdrawByoipCidrOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s WithdrawByoipCidrOutput) GoString() string { - return s.String() -} - -// SetByoipCidr sets the ByoipCidr field's value. -func (s *WithdrawByoipCidrOutput) SetByoipCidr(v *ByoipCidr) *WithdrawByoipCidrOutput { - s.ByoipCidr = v - return s -} - const ( // AccountAttributeNameSupportedPlatforms is a AccountAttributeName enum value AccountAttributeNameSupportedPlatforms = "supported-platforms" @@ -92808,9 +70101,6 @@ const ( // AllocationStateReleasedPermanentFailure is a AllocationState enum value AllocationStateReleasedPermanentFailure = "released-permanent-failure" - - // AllocationStatePending is a AllocationState enum value - AllocationStatePending = "pending" ) const ( @@ -92827,31 +70117,6 @@ const ( // ArchitectureValuesX8664 is a ArchitectureValues enum value ArchitectureValuesX8664 = "x86_64" - - // ArchitectureValuesArm64 is a ArchitectureValues enum value - ArchitectureValuesArm64 = "arm64" -) - -const ( - // AssociatedNetworkTypeVpc is a AssociatedNetworkType enum value - AssociatedNetworkTypeVpc = "vpc" -) - -const ( - // AssociationStatusCodeAssociating is a AssociationStatusCode enum value - AssociationStatusCodeAssociating = "associating" - - // AssociationStatusCodeAssociated is a AssociationStatusCode enum value - AssociationStatusCodeAssociated = "associated" - - // AssociationStatusCodeAssociationFailed is a AssociationStatusCode enum value - AssociationStatusCodeAssociationFailed = "association-failed" - - // AssociationStatusCodeDisassociating is a AssociationStatusCode enum value - AssociationStatusCodeDisassociating = "disassociating" - - // AssociationStatusCodeDisassociated is a AssociationStatusCode enum value - AssociationStatusCodeDisassociated = "disassociated" ) const ( @@ -92868,14 +70133,6 @@ const ( AttachmentStatusDetached = "detached" ) -const ( - // AutoAcceptSharedAttachmentsValueEnable is a AutoAcceptSharedAttachmentsValue enum value - AutoAcceptSharedAttachmentsValueEnable = "enable" - - // AutoAcceptSharedAttachmentsValueDisable is a AutoAcceptSharedAttachmentsValue enum value - AutoAcceptSharedAttachmentsValueDisable = "disable" -) - const ( // AutoPlacementOn is a AutoPlacement enum value AutoPlacementOn = "on" @@ -92944,29 +70201,6 @@ const ( BundleTaskStateFailed = "failed" ) -const ( - // ByoipCidrStateAdvertised is a ByoipCidrState enum value - ByoipCidrStateAdvertised = "advertised" - - // ByoipCidrStateDeprovisioned is a ByoipCidrState enum value - ByoipCidrStateDeprovisioned = "deprovisioned" - - // ByoipCidrStateFailedDeprovision is a ByoipCidrState enum value - ByoipCidrStateFailedDeprovision = "failed-deprovision" - - // ByoipCidrStateFailedProvision is a ByoipCidrState enum value - ByoipCidrStateFailedProvision = "failed-provision" - - // ByoipCidrStatePendingDeprovision is a ByoipCidrState enum value - ByoipCidrStatePendingDeprovision = "pending-deprovision" - - // ByoipCidrStatePendingProvision is a ByoipCidrState enum value - ByoipCidrStatePendingProvision = "pending-provision" - - // ByoipCidrStateProvisioned is a ByoipCidrState enum value - ByoipCidrStateProvisioned = "provisioned" -) - const ( // CancelBatchErrorCodeFleetRequestIdDoesNotExist is a CancelBatchErrorCode enum value CancelBatchErrorCodeFleetRequestIdDoesNotExist = "fleetRequestIdDoesNotExist" @@ -92998,146 +70232,6 @@ const ( CancelSpotInstanceRequestStateCompleted = "completed" ) -const ( - // CapacityReservationInstancePlatformLinuxUnix is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformLinuxUnix = "Linux/UNIX" - - // CapacityReservationInstancePlatformRedHatEnterpriseLinux is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformRedHatEnterpriseLinux = "Red Hat Enterprise Linux" - - // CapacityReservationInstancePlatformSuselinux is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformSuselinux = "SUSE Linux" - - // CapacityReservationInstancePlatformWindows is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformWindows = "Windows" - - // CapacityReservationInstancePlatformWindowswithSqlserver is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformWindowswithSqlserver = "Windows with SQL Server" - - // CapacityReservationInstancePlatformWindowswithSqlserverEnterprise is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformWindowswithSqlserverEnterprise = "Windows with SQL Server Enterprise" - - // CapacityReservationInstancePlatformWindowswithSqlserverStandard is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformWindowswithSqlserverStandard = "Windows with SQL Server Standard" - - // CapacityReservationInstancePlatformWindowswithSqlserverWeb is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformWindowswithSqlserverWeb = "Windows with SQL Server Web" - - // CapacityReservationInstancePlatformLinuxwithSqlserverStandard is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformLinuxwithSqlserverStandard = "Linux with SQL Server Standard" - - // CapacityReservationInstancePlatformLinuxwithSqlserverWeb is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformLinuxwithSqlserverWeb = "Linux with SQL Server Web" - - // CapacityReservationInstancePlatformLinuxwithSqlserverEnterprise is a CapacityReservationInstancePlatform enum value - CapacityReservationInstancePlatformLinuxwithSqlserverEnterprise = "Linux with SQL Server Enterprise" -) - -const ( - // CapacityReservationPreferenceOpen is a CapacityReservationPreference enum value - CapacityReservationPreferenceOpen = "open" - - // CapacityReservationPreferenceNone is a CapacityReservationPreference enum value - CapacityReservationPreferenceNone = "none" -) - -const ( - // CapacityReservationStateActive is a CapacityReservationState enum value - CapacityReservationStateActive = "active" - - // CapacityReservationStateExpired is a CapacityReservationState enum value - CapacityReservationStateExpired = "expired" - - // CapacityReservationStateCancelled is a CapacityReservationState enum value - CapacityReservationStateCancelled = "cancelled" - - // CapacityReservationStatePending is a CapacityReservationState enum value - CapacityReservationStatePending = "pending" - - // CapacityReservationStateFailed is a CapacityReservationState enum value - CapacityReservationStateFailed = "failed" -) - -const ( - // CapacityReservationTenancyDefault is a CapacityReservationTenancy enum value - CapacityReservationTenancyDefault = "default" - - // CapacityReservationTenancyDedicated is a CapacityReservationTenancy enum value - CapacityReservationTenancyDedicated = "dedicated" -) - -const ( - // ClientCertificateRevocationListStatusCodePending is a ClientCertificateRevocationListStatusCode enum value - ClientCertificateRevocationListStatusCodePending = "pending" - - // ClientCertificateRevocationListStatusCodeActive is a ClientCertificateRevocationListStatusCode enum value - ClientCertificateRevocationListStatusCodeActive = "active" -) - -const ( - // ClientVpnAuthenticationTypeCertificateAuthentication is a ClientVpnAuthenticationType enum value - ClientVpnAuthenticationTypeCertificateAuthentication = "certificate-authentication" - - // ClientVpnAuthenticationTypeDirectoryServiceAuthentication is a ClientVpnAuthenticationType enum value - ClientVpnAuthenticationTypeDirectoryServiceAuthentication = "directory-service-authentication" -) - -const ( - // ClientVpnAuthorizationRuleStatusCodeAuthorizing is a ClientVpnAuthorizationRuleStatusCode enum value - ClientVpnAuthorizationRuleStatusCodeAuthorizing = "authorizing" - - // ClientVpnAuthorizationRuleStatusCodeActive is a ClientVpnAuthorizationRuleStatusCode enum value - ClientVpnAuthorizationRuleStatusCodeActive = "active" - - // ClientVpnAuthorizationRuleStatusCodeFailed is a ClientVpnAuthorizationRuleStatusCode enum value - ClientVpnAuthorizationRuleStatusCodeFailed = "failed" - - // ClientVpnAuthorizationRuleStatusCodeRevoking is a ClientVpnAuthorizationRuleStatusCode enum value - ClientVpnAuthorizationRuleStatusCodeRevoking = "revoking" -) - -const ( - // ClientVpnConnectionStatusCodeActive is a ClientVpnConnectionStatusCode enum value - ClientVpnConnectionStatusCodeActive = "active" - - // ClientVpnConnectionStatusCodeFailedToTerminate is a ClientVpnConnectionStatusCode enum value - ClientVpnConnectionStatusCodeFailedToTerminate = "failed-to-terminate" - - // ClientVpnConnectionStatusCodeTerminating is a ClientVpnConnectionStatusCode enum value - ClientVpnConnectionStatusCodeTerminating = "terminating" - - // ClientVpnConnectionStatusCodeTerminated is a ClientVpnConnectionStatusCode enum value - ClientVpnConnectionStatusCodeTerminated = "terminated" -) - -const ( - // ClientVpnEndpointStatusCodePendingAssociate is a ClientVpnEndpointStatusCode enum value - ClientVpnEndpointStatusCodePendingAssociate = "pending-associate" - - // ClientVpnEndpointStatusCodeAvailable is a ClientVpnEndpointStatusCode enum value - ClientVpnEndpointStatusCodeAvailable = "available" - - // ClientVpnEndpointStatusCodeDeleting is a ClientVpnEndpointStatusCode enum value - ClientVpnEndpointStatusCodeDeleting = "deleting" - - // ClientVpnEndpointStatusCodeDeleted is a ClientVpnEndpointStatusCode enum value - ClientVpnEndpointStatusCodeDeleted = "deleted" -) - -const ( - // ClientVpnRouteStatusCodeCreating is a ClientVpnRouteStatusCode enum value - ClientVpnRouteStatusCodeCreating = "creating" - - // ClientVpnRouteStatusCodeActive is a ClientVpnRouteStatusCode enum value - ClientVpnRouteStatusCodeActive = "active" - - // ClientVpnRouteStatusCodeFailed is a ClientVpnRouteStatusCode enum value - ClientVpnRouteStatusCodeFailed = "failed" - - // ClientVpnRouteStatusCodeDeleting is a ClientVpnRouteStatusCode enum value - ClientVpnRouteStatusCodeDeleting = "deleting" -) - const ( // ConnectionNotificationStateEnabled is a ConnectionNotificationState enum value ConnectionNotificationStateEnabled = "Enabled" @@ -93170,11 +70264,6 @@ const ( ConversionTaskStateCompleted = "completed" ) -const ( - // CopyTagsFromSourceVolume is a CopyTagsFromSource enum value - CopyTagsFromSourceVolume = "volume" -) - const ( // CurrencyCodeValuesUsd is a CurrencyCodeValues enum value CurrencyCodeValuesUsd = "USD" @@ -93188,22 +70277,6 @@ const ( DatafeedSubscriptionStateInactive = "Inactive" ) -const ( - // DefaultRouteTableAssociationValueEnable is a DefaultRouteTableAssociationValue enum value - DefaultRouteTableAssociationValueEnable = "enable" - - // DefaultRouteTableAssociationValueDisable is a DefaultRouteTableAssociationValue enum value - DefaultRouteTableAssociationValueDisable = "disable" -) - -const ( - // DefaultRouteTablePropagationValueEnable is a DefaultRouteTablePropagationValue enum value - DefaultRouteTablePropagationValueEnable = "enable" - - // DefaultRouteTablePropagationValueDisable is a DefaultRouteTablePropagationValue enum value - DefaultRouteTablePropagationValueDisable = "disable" -) - const ( // DefaultTargetCapacityTypeSpot is a DefaultTargetCapacityType enum value DefaultTargetCapacityTypeSpot = "spot" @@ -93245,14 +70318,6 @@ const ( DiskImageFormatVhd = "VHD" ) -const ( - // DnsSupportValueEnable is a DnsSupportValue enum value - DnsSupportValueEnable = "enable" - - // DnsSupportValueDisable is a DnsSupportValue enum value - DnsSupportValueDisable = "disable" -) - const ( // DomainTypeVpc is a DomainType enum value DomainTypeVpc = "vpc" @@ -93274,14 +70339,6 @@ const ( ElasticGpuStatusImpaired = "IMPAIRED" ) -const ( - // EndDateTypeUnlimited is a EndDateType enum value - EndDateTypeUnlimited = "unlimited" - - // EndDateTypeLimited is a EndDateType enum value - EndDateTypeLimited = "limited" -) - const ( // EventCodeInstanceReboot is a EventCode enum value EventCodeInstanceReboot = "instance-reboot" @@ -93308,9 +70365,6 @@ const ( // EventTypeError is a EventType enum value EventTypeError = "error" - - // EventTypeInformation is a EventType enum value - EventTypeInformation = "information" ) const ( @@ -93416,9 +70470,6 @@ const ( // FleetTypeMaintain is a FleetType enum value FleetTypeMaintain = "maintain" - - // FleetTypeInstant is a FleetType enum value - FleetTypeInstant = "instant" ) const ( @@ -93465,14 +70516,6 @@ const ( GatewayTypeIpsec1 = "ipsec.1" ) -const ( - // HostRecoveryOn is a HostRecovery enum value - HostRecoveryOn = "on" - - // HostRecoveryOff is a HostRecovery enum value - HostRecoveryOff = "off" -) - const ( // HostTenancyDedicated is a HostTenancy enum value HostTenancyDedicated = "dedicated" @@ -93623,14 +70666,6 @@ const ( InstanceInterruptionBehaviorTerminate = "terminate" ) -const ( - // InstanceLifecycleSpot is a InstanceLifecycle enum value - InstanceLifecycleSpot = "spot" - - // InstanceLifecycleOnDemand is a InstanceLifecycle enum value - InstanceLifecycleOnDemand = "on-demand" -) - const ( // InstanceLifecycleTypeSpot is a InstanceLifecycleType enum value InstanceLifecycleTypeSpot = "spot" @@ -93639,14 +70674,6 @@ const ( InstanceLifecycleTypeScheduled = "scheduled" ) -const ( - // InstanceMatchCriteriaOpen is a InstanceMatchCriteria enum value - InstanceMatchCriteriaOpen = "open" - - // InstanceMatchCriteriaTargeted is a InstanceMatchCriteria enum value - InstanceMatchCriteriaTargeted = "targeted" -) - const ( // InstanceStateNamePending is a InstanceStateName enum value InstanceStateNamePending = "pending" @@ -93713,27 +70740,6 @@ const ( // InstanceTypeT32xlarge is a InstanceType enum value InstanceTypeT32xlarge = "t3.2xlarge" - // InstanceTypeT3aNano is a InstanceType enum value - InstanceTypeT3aNano = "t3a.nano" - - // InstanceTypeT3aMicro is a InstanceType enum value - InstanceTypeT3aMicro = "t3a.micro" - - // InstanceTypeT3aSmall is a InstanceType enum value - InstanceTypeT3aSmall = "t3a.small" - - // InstanceTypeT3aMedium is a InstanceType enum value - InstanceTypeT3aMedium = "t3a.medium" - - // InstanceTypeT3aLarge is a InstanceType enum value - InstanceTypeT3aLarge = "t3a.large" - - // InstanceTypeT3aXlarge is a InstanceType enum value - InstanceTypeT3aXlarge = "t3a.xlarge" - - // InstanceTypeT3a2xlarge is a InstanceType enum value - InstanceTypeT3a2xlarge = "t3a.2xlarge" - // InstanceTypeM1Small is a InstanceType enum value InstanceTypeM1Small = "m1.small" @@ -93848,30 +70854,6 @@ const ( // InstanceTypeR5Metal is a InstanceType enum value InstanceTypeR5Metal = "r5.metal" - // InstanceTypeR5aLarge is a InstanceType enum value - InstanceTypeR5aLarge = "r5a.large" - - // InstanceTypeR5aXlarge is a InstanceType enum value - InstanceTypeR5aXlarge = "r5a.xlarge" - - // InstanceTypeR5a2xlarge is a InstanceType enum value - InstanceTypeR5a2xlarge = "r5a.2xlarge" - - // InstanceTypeR5a4xlarge is a InstanceType enum value - InstanceTypeR5a4xlarge = "r5a.4xlarge" - - // InstanceTypeR5a8xlarge is a InstanceType enum value - InstanceTypeR5a8xlarge = "r5a.8xlarge" - - // InstanceTypeR5a12xlarge is a InstanceType enum value - InstanceTypeR5a12xlarge = "r5a.12xlarge" - - // InstanceTypeR5a16xlarge is a InstanceType enum value - InstanceTypeR5a16xlarge = "r5a.16xlarge" - - // InstanceTypeR5a24xlarge is a InstanceType enum value - InstanceTypeR5a24xlarge = "r5a.24xlarge" - // InstanceTypeR5dLarge is a InstanceType enum value InstanceTypeR5dLarge = "r5d.large" @@ -93899,30 +70881,6 @@ const ( // InstanceTypeR5dMetal is a InstanceType enum value InstanceTypeR5dMetal = "r5d.metal" - // InstanceTypeR5adLarge is a InstanceType enum value - InstanceTypeR5adLarge = "r5ad.large" - - // InstanceTypeR5adXlarge is a InstanceType enum value - InstanceTypeR5adXlarge = "r5ad.xlarge" - - // InstanceTypeR5ad2xlarge is a InstanceType enum value - InstanceTypeR5ad2xlarge = "r5ad.2xlarge" - - // InstanceTypeR5ad4xlarge is a InstanceType enum value - InstanceTypeR5ad4xlarge = "r5ad.4xlarge" - - // InstanceTypeR5ad8xlarge is a InstanceType enum value - InstanceTypeR5ad8xlarge = "r5ad.8xlarge" - - // InstanceTypeR5ad12xlarge is a InstanceType enum value - InstanceTypeR5ad12xlarge = "r5ad.12xlarge" - - // InstanceTypeR5ad16xlarge is a InstanceType enum value - InstanceTypeR5ad16xlarge = "r5ad.16xlarge" - - // InstanceTypeR5ad24xlarge is a InstanceType enum value - InstanceTypeR5ad24xlarge = "r5ad.24xlarge" - // InstanceTypeX116xlarge is a InstanceType enum value InstanceTypeX116xlarge = "x1.16xlarge" @@ -93980,27 +70938,6 @@ const ( // InstanceTypeI3Metal is a InstanceType enum value InstanceTypeI3Metal = "i3.metal" - // InstanceTypeI3enLarge is a InstanceType enum value - InstanceTypeI3enLarge = "i3en.large" - - // InstanceTypeI3enXlarge is a InstanceType enum value - InstanceTypeI3enXlarge = "i3en.xlarge" - - // InstanceTypeI3en2xlarge is a InstanceType enum value - InstanceTypeI3en2xlarge = "i3en.2xlarge" - - // InstanceTypeI3en3xlarge is a InstanceType enum value - InstanceTypeI3en3xlarge = "i3en.3xlarge" - - // InstanceTypeI3en6xlarge is a InstanceType enum value - InstanceTypeI3en6xlarge = "i3en.6xlarge" - - // InstanceTypeI3en12xlarge is a InstanceType enum value - InstanceTypeI3en12xlarge = "i3en.12xlarge" - - // InstanceTypeI3en24xlarge is a InstanceType enum value - InstanceTypeI3en24xlarge = "i3en.24xlarge" - // InstanceTypeHi14xlarge is a InstanceType enum value InstanceTypeHi14xlarge = "hi1.4xlarge" @@ -94058,18 +70995,9 @@ const ( // InstanceTypeC59xlarge is a InstanceType enum value InstanceTypeC59xlarge = "c5.9xlarge" - // InstanceTypeC512xlarge is a InstanceType enum value - InstanceTypeC512xlarge = "c5.12xlarge" - // InstanceTypeC518xlarge is a InstanceType enum value InstanceTypeC518xlarge = "c5.18xlarge" - // InstanceTypeC524xlarge is a InstanceType enum value - InstanceTypeC524xlarge = "c5.24xlarge" - - // InstanceTypeC5Metal is a InstanceType enum value - InstanceTypeC5Metal = "c5.metal" - // InstanceTypeC5dLarge is a InstanceType enum value InstanceTypeC5dLarge = "c5d.large" @@ -94088,24 +71016,6 @@ const ( // InstanceTypeC5d18xlarge is a InstanceType enum value InstanceTypeC5d18xlarge = "c5d.18xlarge" - // InstanceTypeC5nLarge is a InstanceType enum value - InstanceTypeC5nLarge = "c5n.large" - - // InstanceTypeC5nXlarge is a InstanceType enum value - InstanceTypeC5nXlarge = "c5n.xlarge" - - // InstanceTypeC5n2xlarge is a InstanceType enum value - InstanceTypeC5n2xlarge = "c5n.2xlarge" - - // InstanceTypeC5n4xlarge is a InstanceType enum value - InstanceTypeC5n4xlarge = "c5n.4xlarge" - - // InstanceTypeC5n9xlarge is a InstanceType enum value - InstanceTypeC5n9xlarge = "c5n.9xlarge" - - // InstanceTypeC5n18xlarge is a InstanceType enum value - InstanceTypeC5n18xlarge = "c5n.18xlarge" - // InstanceTypeCc14xlarge is a InstanceType enum value InstanceTypeCc14xlarge = "cc1.4xlarge" @@ -94127,9 +71037,6 @@ const ( // InstanceTypeG316xlarge is a InstanceType enum value InstanceTypeG316xlarge = "g3.16xlarge" - // InstanceTypeG3sXlarge is a InstanceType enum value - InstanceTypeG3sXlarge = "g3s.xlarge" - // InstanceTypeCg14xlarge is a InstanceType enum value InstanceTypeCg14xlarge = "cg1.4xlarge" @@ -94151,9 +71058,6 @@ const ( // InstanceTypeP316xlarge is a InstanceType enum value InstanceTypeP316xlarge = "p3.16xlarge" - // InstanceTypeP3dn24xlarge is a InstanceType enum value - InstanceTypeP3dn24xlarge = "p3dn.24xlarge" - // InstanceTypeD2Xlarge is a InstanceType enum value InstanceTypeD2Xlarge = "d2.xlarge" @@ -94169,9 +71073,6 @@ const ( // InstanceTypeF12xlarge is a InstanceType enum value InstanceTypeF12xlarge = "f1.2xlarge" - // InstanceTypeF14xlarge is a InstanceType enum value - InstanceTypeF14xlarge = "f1.4xlarge" - // InstanceTypeF116xlarge is a InstanceType enum value InstanceTypeF116xlarge = "f1.16xlarge" @@ -94187,45 +71088,12 @@ const ( // InstanceTypeM54xlarge is a InstanceType enum value InstanceTypeM54xlarge = "m5.4xlarge" - // InstanceTypeM58xlarge is a InstanceType enum value - InstanceTypeM58xlarge = "m5.8xlarge" - // InstanceTypeM512xlarge is a InstanceType enum value InstanceTypeM512xlarge = "m5.12xlarge" - // InstanceTypeM516xlarge is a InstanceType enum value - InstanceTypeM516xlarge = "m5.16xlarge" - // InstanceTypeM524xlarge is a InstanceType enum value InstanceTypeM524xlarge = "m5.24xlarge" - // InstanceTypeM5Metal is a InstanceType enum value - InstanceTypeM5Metal = "m5.metal" - - // InstanceTypeM5aLarge is a InstanceType enum value - InstanceTypeM5aLarge = "m5a.large" - - // InstanceTypeM5aXlarge is a InstanceType enum value - InstanceTypeM5aXlarge = "m5a.xlarge" - - // InstanceTypeM5a2xlarge is a InstanceType enum value - InstanceTypeM5a2xlarge = "m5a.2xlarge" - - // InstanceTypeM5a4xlarge is a InstanceType enum value - InstanceTypeM5a4xlarge = "m5a.4xlarge" - - // InstanceTypeM5a8xlarge is a InstanceType enum value - InstanceTypeM5a8xlarge = "m5a.8xlarge" - - // InstanceTypeM5a12xlarge is a InstanceType enum value - InstanceTypeM5a12xlarge = "m5a.12xlarge" - - // InstanceTypeM5a16xlarge is a InstanceType enum value - InstanceTypeM5a16xlarge = "m5a.16xlarge" - - // InstanceTypeM5a24xlarge is a InstanceType enum value - InstanceTypeM5a24xlarge = "m5a.24xlarge" - // InstanceTypeM5dLarge is a InstanceType enum value InstanceTypeM5dLarge = "m5d.large" @@ -94238,45 +71106,12 @@ const ( // InstanceTypeM5d4xlarge is a InstanceType enum value InstanceTypeM5d4xlarge = "m5d.4xlarge" - // InstanceTypeM5d8xlarge is a InstanceType enum value - InstanceTypeM5d8xlarge = "m5d.8xlarge" - // InstanceTypeM5d12xlarge is a InstanceType enum value InstanceTypeM5d12xlarge = "m5d.12xlarge" - // InstanceTypeM5d16xlarge is a InstanceType enum value - InstanceTypeM5d16xlarge = "m5d.16xlarge" - // InstanceTypeM5d24xlarge is a InstanceType enum value InstanceTypeM5d24xlarge = "m5d.24xlarge" - // InstanceTypeM5dMetal is a InstanceType enum value - InstanceTypeM5dMetal = "m5d.metal" - - // InstanceTypeM5adLarge is a InstanceType enum value - InstanceTypeM5adLarge = "m5ad.large" - - // InstanceTypeM5adXlarge is a InstanceType enum value - InstanceTypeM5adXlarge = "m5ad.xlarge" - - // InstanceTypeM5ad2xlarge is a InstanceType enum value - InstanceTypeM5ad2xlarge = "m5ad.2xlarge" - - // InstanceTypeM5ad4xlarge is a InstanceType enum value - InstanceTypeM5ad4xlarge = "m5ad.4xlarge" - - // InstanceTypeM5ad8xlarge is a InstanceType enum value - InstanceTypeM5ad8xlarge = "m5ad.8xlarge" - - // InstanceTypeM5ad12xlarge is a InstanceType enum value - InstanceTypeM5ad12xlarge = "m5ad.12xlarge" - - // InstanceTypeM5ad16xlarge is a InstanceType enum value - InstanceTypeM5ad16xlarge = "m5ad.16xlarge" - - // InstanceTypeM5ad24xlarge is a InstanceType enum value - InstanceTypeM5ad24xlarge = "m5ad.24xlarge" - // InstanceTypeH12xlarge is a InstanceType enum value InstanceTypeH12xlarge = "h1.2xlarge" @@ -94306,33 +71141,6 @@ const ( // InstanceTypeZ1d12xlarge is a InstanceType enum value InstanceTypeZ1d12xlarge = "z1d.12xlarge" - - // InstanceTypeZ1dMetal is a InstanceType enum value - InstanceTypeZ1dMetal = "z1d.metal" - - // InstanceTypeU6tb1Metal is a InstanceType enum value - InstanceTypeU6tb1Metal = "u-6tb1.metal" - - // InstanceTypeU9tb1Metal is a InstanceType enum value - InstanceTypeU9tb1Metal = "u-9tb1.metal" - - // InstanceTypeU12tb1Metal is a InstanceType enum value - InstanceTypeU12tb1Metal = "u-12tb1.metal" - - // InstanceTypeA1Medium is a InstanceType enum value - InstanceTypeA1Medium = "a1.medium" - - // InstanceTypeA1Large is a InstanceType enum value - InstanceTypeA1Large = "a1.large" - - // InstanceTypeA1Xlarge is a InstanceType enum value - InstanceTypeA1Xlarge = "a1.xlarge" - - // InstanceTypeA12xlarge is a InstanceType enum value - InstanceTypeA12xlarge = "a1.2xlarge" - - // InstanceTypeA14xlarge is a InstanceType enum value - InstanceTypeA14xlarge = "a1.4xlarge" ) const ( @@ -94343,14 +71151,6 @@ const ( InterfacePermissionTypeEipAssociate = "EIP-ASSOCIATE" ) -const ( - // Ipv6SupportValueEnable is a Ipv6SupportValue enum value - Ipv6SupportValueEnable = "enable" - - // Ipv6SupportValueDisable is a Ipv6SupportValue enum value - Ipv6SupportValueDisable = "disable" -) - const ( // LaunchTemplateErrorCodeLaunchTemplateIdDoesNotExist is a LaunchTemplateErrorCode enum value LaunchTemplateErrorCodeLaunchTemplateIdDoesNotExist = "launchTemplateIdDoesNotExist" @@ -94465,11 +71265,6 @@ const ( NetworkInterfaceAttributeAttachment = "attachment" ) -const ( - // NetworkInterfaceCreationTypeEfa is a NetworkInterfaceCreationType enum value - NetworkInterfaceCreationTypeEfa = "efa" -) - const ( // NetworkInterfacePermissionStateCodePending is a NetworkInterfacePermissionStateCode enum value NetworkInterfacePermissionStateCodePending = "pending" @@ -94507,9 +71302,6 @@ const ( // NetworkInterfaceTypeNatGateway is a NetworkInterfaceType enum value NetworkInterfaceTypeNatGateway = "natGateway" - - // NetworkInterfaceTypeEfa is a NetworkInterfaceType enum value - NetworkInterfaceTypeEfa = "efa" ) const ( @@ -94592,9 +71384,6 @@ const ( // PlacementStrategySpread is a PlacementStrategy enum value PlacementStrategySpread = "spread" - - // PlacementStrategyPartition is a PlacementStrategy enum value - PlacementStrategyPartition = "partition" ) const ( @@ -94725,30 +71514,12 @@ const ( ) const ( - // ResourceTypeClientVpnEndpoint is a ResourceType enum value - ResourceTypeClientVpnEndpoint = "client-vpn-endpoint" - // ResourceTypeCustomerGateway is a ResourceType enum value ResourceTypeCustomerGateway = "customer-gateway" - // ResourceTypeDedicatedHost is a ResourceType enum value - ResourceTypeDedicatedHost = "dedicated-host" - // ResourceTypeDhcpOptions is a ResourceType enum value ResourceTypeDhcpOptions = "dhcp-options" - // ResourceTypeElasticIp is a ResourceType enum value - ResourceTypeElasticIp = "elastic-ip" - - // ResourceTypeFleet is a ResourceType enum value - ResourceTypeFleet = "fleet" - - // ResourceTypeFpgaImage is a ResourceType enum value - ResourceTypeFpgaImage = "fpga-image" - - // ResourceTypeHostReservation is a ResourceType enum value - ResourceTypeHostReservation = "host-reservation" - // ResourceTypeImage is a ResourceType enum value ResourceTypeImage = "image" @@ -94758,12 +71529,6 @@ const ( // ResourceTypeInternetGateway is a ResourceType enum value ResourceTypeInternetGateway = "internet-gateway" - // ResourceTypeLaunchTemplate is a ResourceType enum value - ResourceTypeLaunchTemplate = "launch-template" - - // ResourceTypeNatgateway is a ResourceType enum value - ResourceTypeNatgateway = "natgateway" - // ResourceTypeNetworkAcl is a ResourceType enum value ResourceTypeNetworkAcl = "network-acl" @@ -94776,9 +71541,6 @@ const ( // ResourceTypeRouteTable is a ResourceType enum value ResourceTypeRouteTable = "route-table" - // ResourceTypeSecurityGroup is a ResourceType enum value - ResourceTypeSecurityGroup = "security-group" - // ResourceTypeSnapshot is a ResourceType enum value ResourceTypeSnapshot = "snapshot" @@ -94788,23 +71550,8 @@ const ( // ResourceTypeSubnet is a ResourceType enum value ResourceTypeSubnet = "subnet" - // ResourceTypeTrafficMirrorFilter is a ResourceType enum value - ResourceTypeTrafficMirrorFilter = "traffic-mirror-filter" - - // ResourceTypeTrafficMirrorSession is a ResourceType enum value - ResourceTypeTrafficMirrorSession = "traffic-mirror-session" - - // ResourceTypeTrafficMirrorTarget is a ResourceType enum value - ResourceTypeTrafficMirrorTarget = "traffic-mirror-target" - - // ResourceTypeTransitGateway is a ResourceType enum value - ResourceTypeTransitGateway = "transit-gateway" - - // ResourceTypeTransitGatewayAttachment is a ResourceType enum value - ResourceTypeTransitGatewayAttachment = "transit-gateway-attachment" - - // ResourceTypeTransitGatewayRouteTable is a ResourceType enum value - ResourceTypeTransitGatewayRouteTable = "transit-gateway-route-table" + // ResourceTypeSecurityGroup is a ResourceType enum value + ResourceTypeSecurityGroup = "security-group" // ResourceTypeVolume is a ResourceType enum value ResourceTypeVolume = "volume" @@ -94812,9 +71559,6 @@ const ( // ResourceTypeVpc is a ResourceType enum value ResourceTypeVpc = "vpc" - // ResourceTypeVpcPeeringConnection is a ResourceType enum value - ResourceTypeVpcPeeringConnection = "vpc-peering-connection" - // ResourceTypeVpnConnection is a ResourceType enum value ResourceTypeVpnConnection = "vpn-connection" @@ -95065,60 +71809,6 @@ const ( TenancyHost = "host" ) -const ( - // TrafficDirectionIngress is a TrafficDirection enum value - TrafficDirectionIngress = "ingress" - - // TrafficDirectionEgress is a TrafficDirection enum value - TrafficDirectionEgress = "egress" -) - -const ( - // TrafficMirrorFilterRuleFieldDestinationPortRange is a TrafficMirrorFilterRuleField enum value - TrafficMirrorFilterRuleFieldDestinationPortRange = "destination-port-range" - - // TrafficMirrorFilterRuleFieldSourcePortRange is a TrafficMirrorFilterRuleField enum value - TrafficMirrorFilterRuleFieldSourcePortRange = "source-port-range" - - // TrafficMirrorFilterRuleFieldProtocol is a TrafficMirrorFilterRuleField enum value - TrafficMirrorFilterRuleFieldProtocol = "protocol" - - // TrafficMirrorFilterRuleFieldDescription is a TrafficMirrorFilterRuleField enum value - TrafficMirrorFilterRuleFieldDescription = "description" -) - -const ( - // TrafficMirrorNetworkServiceAmazonDns is a TrafficMirrorNetworkService enum value - TrafficMirrorNetworkServiceAmazonDns = "amazon-dns" -) - -const ( - // TrafficMirrorRuleActionAccept is a TrafficMirrorRuleAction enum value - TrafficMirrorRuleActionAccept = "accept" - - // TrafficMirrorRuleActionReject is a TrafficMirrorRuleAction enum value - TrafficMirrorRuleActionReject = "reject" -) - -const ( - // TrafficMirrorSessionFieldPacketLength is a TrafficMirrorSessionField enum value - TrafficMirrorSessionFieldPacketLength = "packet-length" - - // TrafficMirrorSessionFieldDescription is a TrafficMirrorSessionField enum value - TrafficMirrorSessionFieldDescription = "description" - - // TrafficMirrorSessionFieldVirtualNetworkId is a TrafficMirrorSessionField enum value - TrafficMirrorSessionFieldVirtualNetworkId = "virtual-network-id" -) - -const ( - // TrafficMirrorTargetTypeNetworkInterface is a TrafficMirrorTargetType enum value - TrafficMirrorTargetTypeNetworkInterface = "network-interface" - - // TrafficMirrorTargetTypeNetworkLoadBalancer is a TrafficMirrorTargetType enum value - TrafficMirrorTargetTypeNetworkLoadBalancer = "network-load-balancer" -) - const ( // TrafficTypeAccept is a TrafficType enum value TrafficTypeAccept = "ACCEPT" @@ -95130,144 +71820,6 @@ const ( TrafficTypeAll = "ALL" ) -const ( - // TransitGatewayAssociationStateAssociating is a TransitGatewayAssociationState enum value - TransitGatewayAssociationStateAssociating = "associating" - - // TransitGatewayAssociationStateAssociated is a TransitGatewayAssociationState enum value - TransitGatewayAssociationStateAssociated = "associated" - - // TransitGatewayAssociationStateDisassociating is a TransitGatewayAssociationState enum value - TransitGatewayAssociationStateDisassociating = "disassociating" - - // TransitGatewayAssociationStateDisassociated is a TransitGatewayAssociationState enum value - TransitGatewayAssociationStateDisassociated = "disassociated" -) - -const ( - // TransitGatewayAttachmentResourceTypeVpc is a TransitGatewayAttachmentResourceType enum value - TransitGatewayAttachmentResourceTypeVpc = "vpc" - - // TransitGatewayAttachmentResourceTypeVpn is a TransitGatewayAttachmentResourceType enum value - TransitGatewayAttachmentResourceTypeVpn = "vpn" - - // TransitGatewayAttachmentResourceTypeDirectConnectGateway is a TransitGatewayAttachmentResourceType enum value - TransitGatewayAttachmentResourceTypeDirectConnectGateway = "direct-connect-gateway" -) - -const ( - // TransitGatewayAttachmentStatePendingAcceptance is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStatePendingAcceptance = "pendingAcceptance" - - // TransitGatewayAttachmentStateRollingBack is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateRollingBack = "rollingBack" - - // TransitGatewayAttachmentStatePending is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStatePending = "pending" - - // TransitGatewayAttachmentStateAvailable is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateAvailable = "available" - - // TransitGatewayAttachmentStateModifying is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateModifying = "modifying" - - // TransitGatewayAttachmentStateDeleting is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateDeleting = "deleting" - - // TransitGatewayAttachmentStateDeleted is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateDeleted = "deleted" - - // TransitGatewayAttachmentStateFailed is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateFailed = "failed" - - // TransitGatewayAttachmentStateRejected is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateRejected = "rejected" - - // TransitGatewayAttachmentStateRejecting is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateRejecting = "rejecting" - - // TransitGatewayAttachmentStateFailing is a TransitGatewayAttachmentState enum value - TransitGatewayAttachmentStateFailing = "failing" -) - -const ( - // TransitGatewayPropagationStateEnabling is a TransitGatewayPropagationState enum value - TransitGatewayPropagationStateEnabling = "enabling" - - // TransitGatewayPropagationStateEnabled is a TransitGatewayPropagationState enum value - TransitGatewayPropagationStateEnabled = "enabled" - - // TransitGatewayPropagationStateDisabling is a TransitGatewayPropagationState enum value - TransitGatewayPropagationStateDisabling = "disabling" - - // TransitGatewayPropagationStateDisabled is a TransitGatewayPropagationState enum value - TransitGatewayPropagationStateDisabled = "disabled" -) - -const ( - // TransitGatewayRouteStatePending is a TransitGatewayRouteState enum value - TransitGatewayRouteStatePending = "pending" - - // TransitGatewayRouteStateActive is a TransitGatewayRouteState enum value - TransitGatewayRouteStateActive = "active" - - // TransitGatewayRouteStateBlackhole is a TransitGatewayRouteState enum value - TransitGatewayRouteStateBlackhole = "blackhole" - - // TransitGatewayRouteStateDeleting is a TransitGatewayRouteState enum value - TransitGatewayRouteStateDeleting = "deleting" - - // TransitGatewayRouteStateDeleted is a TransitGatewayRouteState enum value - TransitGatewayRouteStateDeleted = "deleted" -) - -const ( - // TransitGatewayRouteTableStatePending is a TransitGatewayRouteTableState enum value - TransitGatewayRouteTableStatePending = "pending" - - // TransitGatewayRouteTableStateAvailable is a TransitGatewayRouteTableState enum value - TransitGatewayRouteTableStateAvailable = "available" - - // TransitGatewayRouteTableStateDeleting is a TransitGatewayRouteTableState enum value - TransitGatewayRouteTableStateDeleting = "deleting" - - // TransitGatewayRouteTableStateDeleted is a TransitGatewayRouteTableState enum value - TransitGatewayRouteTableStateDeleted = "deleted" -) - -const ( - // TransitGatewayRouteTypeStatic is a TransitGatewayRouteType enum value - TransitGatewayRouteTypeStatic = "static" - - // TransitGatewayRouteTypePropagated is a TransitGatewayRouteType enum value - TransitGatewayRouteTypePropagated = "propagated" -) - -const ( - // TransitGatewayStatePending is a TransitGatewayState enum value - TransitGatewayStatePending = "pending" - - // TransitGatewayStateAvailable is a TransitGatewayState enum value - TransitGatewayStateAvailable = "available" - - // TransitGatewayStateModifying is a TransitGatewayState enum value - TransitGatewayStateModifying = "modifying" - - // TransitGatewayStateDeleting is a TransitGatewayState enum value - TransitGatewayStateDeleting = "deleting" - - // TransitGatewayStateDeleted is a TransitGatewayState enum value - TransitGatewayStateDeleted = "deleted" -) - -const ( - // TransportProtocolTcp is a TransportProtocol enum value - TransportProtocolTcp = "tcp" - - // TransportProtocolUdp is a TransportProtocol enum value - TransportProtocolUdp = "udp" -) - const ( // UnsuccessfulInstanceCreditSpecificationErrorCodeInvalidInstanceIdMalformed is a UnsuccessfulInstanceCreditSpecificationErrorCode enum value UnsuccessfulInstanceCreditSpecificationErrorCodeInvalidInstanceIdMalformed = "InvalidInstanceID.Malformed" @@ -95463,19 +72015,6 @@ const ( VpcTenancyDefault = "default" ) -const ( - // VpnEcmpSupportValueEnable is a VpnEcmpSupportValue enum value - VpnEcmpSupportValueEnable = "enable" - - // VpnEcmpSupportValueDisable is a VpnEcmpSupportValue enum value - VpnEcmpSupportValueDisable = "disable" -) - -const ( - // VpnProtocolOpenvpn is a VpnProtocol enum value - VpnProtocolOpenvpn = "openvpn" -) - const ( // VpnStatePending is a VpnState enum value VpnStatePending = "pending" diff --git a/vendor/github.com/aws/aws-sdk-go/service/ec2/doc.go b/vendor/github.com/aws/aws-sdk-go/service/ec2/doc.go index e403b84a4..c258e0e85 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/ec2/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/ec2/doc.go @@ -7,19 +7,18 @@ // capacity in the AWS cloud. Using Amazon EC2 eliminates the need to invest // in hardware up front, so you can develop and deploy applications faster. // -// To learn more, see the following resources: +// To learn more about Amazon EC2, Amazon EBS, and Amazon VPC, see the following +// resources: // -// * Amazon EC2: Amazon EC2 product page (http://aws.amazon.com/ec2), Amazon -// EC2 documentation (http://aws.amazon.com/documentation/ec2) +// * Amazon EC2 product page (http://aws.amazon.com/ec2) // -// * Amazon EBS: Amazon EBS product page (http://aws.amazon.com/ebs), Amazon -// EBS documentation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/AmazonEBS.html) +// * Amazon EC2 documentation (http://aws.amazon.com/documentation/ec2) // -// * Amazon VPC: Amazon VPC product page (http://aws.amazon.com/vpc), Amazon -// VPC documentation (http://aws.amazon.com/documentation/vpc) +// * Amazon EBS product page (http://aws.amazon.com/ebs) // -// * AWS VPN: AWS VPN product page (http://aws.amazon.com/vpn), AWS VPN documentation -// (http://aws.amazon.com/documentation/vpn) +// * Amazon VPC product page (http://aws.amazon.com/vpc) +// +// * Amazon VPC documentation (http://aws.amazon.com/documentation/vpc) // // See https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15 for more information on this service. // diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go index 9e610591a..6f89a796e 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sts/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sts/api.go @@ -3,12 +3,10 @@ package sts import ( - "fmt" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" - "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/request" ) @@ -17,7 +15,7 @@ const opAssumeRole = "AssumeRole" // AssumeRoleRequest generates a "aws/request.Request" representing the // client's request for the AssumeRole operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -56,26 +54,38 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o // AssumeRole API operation for AWS Security Token Service. // -// Returns a set of temporary security credentials that you can use to access -// AWS resources that you might not normally have access to. These temporary -// credentials consist of an access key ID, a secret access key, and a security -// token. Typically, you use AssumeRole within your account or for cross-account -// access. For a comparison of AssumeRole with other API operations that produce -// temporary credentials, see Requesting Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) -// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) +// Returns a set of temporary security credentials (consisting of an access +// key ID, a secret access key, and a security token) that you can use to access +// AWS resources that you might not normally have access to. Typically, you +// use AssumeRole for cross-account access or federation. For a comparison of +// AssumeRole with the other APIs that produce temporary credentials, see Requesting +// Temporary Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) +// and Comparing the AWS STS APIs (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) // in the IAM User Guide. // -// You cannot use AWS account root user credentials to call AssumeRole. You -// must use credentials for an IAM user or an IAM role to call AssumeRole. +// Important: You cannot call AssumeRole by using AWS root account credentials; +// access is denied. You must use credentials for an IAM user or an IAM role +// to call AssumeRole. // // For cross-account access, imagine that you own multiple accounts and need // to access resources in each account. You could create long-term credentials // in each account to access those resources. However, managing all those credentials // and remembering which one can access which account can be time consuming. -// Instead, you can create one set of long-term credentials in one account. -// Then use temporary security credentials to access all the other accounts +// Instead, you can create one set of long-term credentials in one account and +// then use temporary security credentials to access all the other accounts // by assuming roles in those accounts. For more information about roles, see -// IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles.html) +// IAM Roles (Delegation and Federation) (http://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html) +// in the IAM User Guide. +// +// For federation, you can, for example, grant single sign-on access to the +// AWS Management Console. If you already have an identity and authentication +// system in your corporate network, you don't have to recreate user identities +// in AWS in order to grant those user identities access to AWS. Instead, after +// a user has been authenticated, you call AssumeRole (and specify the role +// with the appropriate permissions) to get temporary security credentials for +// that user. With those temporary security credentials, you construct a sign-in +// URL that users can use to access the console. For more information, see Common +// Scenarios for Temporary Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html#sts-introduction) // in the IAM User Guide. // // By default, the temporary security credentials created by AssumeRole last @@ -84,73 +94,69 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o // seconds (15 minutes) up to the maximum session duration setting for the role. // This setting can have a value from 1 hour to 12 hours. To learn how to view // the maximum value for your role, see View the Maximum Session Duration Setting -// for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. The maximum session duration limit applies when you -// use the AssumeRole* API operations or the assume-role* CLI commands. However -// the limit does not apply when you use those operations to create a console -// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) // in the IAM User Guide. // // The temporary security credentials created by AssumeRole can be used to make -// API calls to any AWS service with the following exception: You cannot call -// the AWS STS GetFederationToken or GetSessionToken API operations. +// API calls to any AWS service with the following exception: you cannot call +// the STS service's GetFederationToken or GetSessionToken APIs. // -// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) -// to this operation. You can pass a single JSON policy document to use as an -// inline session policy. You can also specify up to 10 managed policies to -// use as managed session policies. The plain text that you use for both inline -// and managed session policies shouldn't exceed 2048 characters. Passing policies -// to this operation returns new temporary credentials. The resulting session's -// permissions are the intersection of the role's identity-based policy and -// the session policies. You can use the role's temporary credentials in subsequent -// AWS API calls to access resources in the account that owns the role. You -// cannot use session policies to grant more permissions than those allowed -// by the identity-based policy of the role that is being assumed. For more -// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) +// Optionally, you can pass an IAM access policy to this operation. If you choose +// not to pass a policy, the temporary security credentials that are returned +// by the operation have the permissions that are defined in the access policy +// of the role that is being assumed. If you pass a policy to this operation, +// the temporary security credentials that are returned by the operation have +// the permissions that are allowed by both the access policy of the role that +// is being assumed, and the policy that you pass. This gives you a way to further +// restrict the permissions for the resulting temporary security credentials. +// You cannot use the passed policy to grant permissions that are in excess +// of those allowed by the access policy of the role that is being assumed. +// For more information, see Permissions for AssumeRole, AssumeRoleWithSAML, +// and AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // -// To assume a role from a different account, your AWS account must be trusted -// by the role. The trust relationship is defined in the role's trust policy -// when the role is created. That trust policy states which accounts are allowed -// to delegate that access to users in the account. +// To assume a role, your AWS account must be trusted by the role. The trust +// relationship is defined in the role's trust policy when the role is created. +// That trust policy states which accounts are allowed to delegate access to +// this account's role. // -// A user who wants to access a role in a different account must also have permissions -// that are delegated from the user account administrator. The administrator -// must attach a policy that allows the user to call AssumeRole for the ARN -// of the role in the other account. If the user is in the same account as the -// role, then you can do either of the following: -// -// * Attach a policy to the user (identical to the previous user in a different -// account). -// -// * Add the user as a principal directly in the role's trust policy. -// -// In this case, the trust policy acts as an IAM resource-based policy. Users -// in the same account as the role do not need explicit permission to assume -// the role. For more information about trust policies and resource-based policies, -// see IAM Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html) +// The user who wants to access the role must also have permissions delegated +// from the role's administrator. If the user is in a different account than +// the role, then the user's administrator must attach a policy that allows +// the user to call AssumeRole on the ARN of the role in the other account. +// If the user is in the same account as the role, then you can either attach +// a policy to the user (identical to the previous different account user), +// or you can add the user as a principal directly in the role's trust policy. +// In this case, the trust policy acts as the only resource-based policy in +// IAM, and users in the same account as the role do not need explicit permission +// to assume the role. For more information about trust policies and resource-based +// policies, see IAM Policies (http://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html) // in the IAM User Guide. // // Using MFA with AssumeRole // -// (Optional) You can include multi-factor authentication (MFA) information -// when you call AssumeRole. This is useful for cross-account scenarios to ensure -// that the user that assumes the role has been authenticated with an AWS MFA -// device. In that scenario, the trust policy of the role being assumed includes -// a condition that tests for MFA authentication. If the caller does not include -// valid MFA information, the request to assume the role is denied. The condition -// in a trust policy that tests for MFA authentication might look like the following -// example. +// You can optionally include multi-factor authentication (MFA) information +// when you call AssumeRole. This is useful for cross-account scenarios in which +// you want to make sure that the user who is assuming the role has been authenticated +// using an AWS MFA device. In that scenario, the trust policy of the role being +// assumed includes a condition that tests for MFA authentication; if the caller +// does not include valid MFA information, the request to assume the role is +// denied. The condition in a trust policy that tests for MFA authentication +// might look like the following example. // // "Condition": {"Bool": {"aws:MultiFactorAuthPresent": true}} // -// For more information, see Configuring MFA-Protected API Access (https://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html) +// For more information, see Configuring MFA-Protected API Access (http://docs.aws.amazon.com/IAM/latest/UserGuide/MFAProtectedAPI.html) // in the IAM User Guide guide. // // To use MFA with AssumeRole, you pass values for the SerialNumber and TokenCode // parameters. The SerialNumber value identifies the user's hardware or virtual // MFA device. The TokenCode is the time-based one-time password (TOTP) that -// the MFA device produces. +// the MFA devices produces. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -173,7 +179,7 @@ func (c *STS) AssumeRoleRequest(input *AssumeRoleInput) (req *request.Request, o // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating -// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRole @@ -203,7 +209,7 @@ const opAssumeRoleWithSAML = "AssumeRoleWithSAML" // AssumeRoleWithSAMLRequest generates a "aws/request.Request" representing the // client's request for the AssumeRoleWithSAML operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -237,7 +243,6 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re output = &AssumeRoleWithSAMLOutput{} req = c.newRequest(op, input, output) - req.Config.Credentials = credentials.AnonymousCredentials return } @@ -247,9 +252,9 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re // via a SAML authentication response. This operation provides a mechanism for // tying an enterprise identity store or directory to role-based AWS access // without user-specific credentials or configuration. For a comparison of AssumeRoleWithSAML -// with the other API operations that produce temporary credentials, see Requesting -// Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) -// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) +// with the other APIs that produce temporary credentials, see Requesting Temporary +// Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) +// and Comparing the AWS STS APIs (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) // in the IAM User Guide. // // The temporary security credentials returned by this operation consist of @@ -264,36 +269,37 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re // a DurationSeconds value from 900 seconds (15 minutes) up to the maximum session // duration setting for the role. This setting can have a value from 1 hour // to 12 hours. To learn how to view the maximum value for your role, see View -// the Maximum Session Duration Setting for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// the Maximum Session Duration Setting for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. The maximum session duration limit applies when you -// use the AssumeRole* API operations or the assume-role* CLI commands. However -// the limit does not apply when you use those operations to create a console -// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) // in the IAM User Guide. // // The temporary security credentials created by AssumeRoleWithSAML can be used // to make API calls to any AWS service with the following exception: you cannot -// call the STS GetFederationToken or GetSessionToken API operations. +// call the STS service's GetFederationToken or GetSessionToken APIs. // -// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) -// to this operation. You can pass a single JSON policy document to use as an -// inline session policy. You can also specify up to 10 managed policies to -// use as managed session policies. The plain text that you use for both inline -// and managed session policies shouldn't exceed 2048 characters. Passing policies -// to this operation returns new temporary credentials. The resulting session's -// permissions are the intersection of the role's identity-based policy and -// the session policies. You can use the role's temporary credentials in subsequent -// AWS API calls to access resources in the account that owns the role. You -// cannot use session policies to grant more permissions than those allowed -// by the identity-based policy of the role that is being assumed. For more -// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) +// Optionally, you can pass an IAM access policy to this operation. If you choose +// not to pass a policy, the temporary security credentials that are returned +// by the operation have the permissions that are defined in the access policy +// of the role that is being assumed. If you pass a policy to this operation, +// the temporary security credentials that are returned by the operation have +// the permissions that are allowed by the intersection of both the access policy +// of the role that is being assumed, and the policy that you pass. This means +// that both policies must grant the permission for the action to be allowed. +// This gives you a way to further restrict the permissions for the resulting +// temporary security credentials. You cannot use the passed policy to grant +// permissions that are in excess of those allowed by the access policy of the +// role that is being assumed. For more information, see Permissions for AssumeRole, +// AssumeRoleWithSAML, and AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // // Before your application can call AssumeRoleWithSAML, you must configure your // SAML identity provider (IdP) to issue the claims required by AWS. Additionally, // you must use AWS Identity and Access Management (IAM) to create a SAML provider -// entity in your AWS account that represents your identity provider. You must -// also create an IAM role that specifies this SAML provider in its trust policy. +// entity in your AWS account that represents your identity provider, and create +// an IAM role that specifies this SAML provider in its trust policy. // // Calling AssumeRoleWithSAML does not require the use of AWS security credentials. // The identity of the caller is validated by using keys in the metadata document @@ -307,16 +313,16 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re // // For more information, see the following resources: // -// * About SAML 2.0-based Federation (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html) +// * About SAML 2.0-based Federation (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_saml.html) // in the IAM User Guide. // -// * Creating SAML Identity Providers (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html) +// * Creating SAML Identity Providers (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml.html) // in the IAM User Guide. // -// * Configuring a Relying Party and Claims (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html) +// * Configuring a Relying Party and Claims (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_saml_relying-party.html) // in the IAM User Guide. // -// * Creating a Role for SAML 2.0 Federation (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html) +// * Creating a Role for SAML 2.0 Federation (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-idp_saml.html) // in the IAM User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -355,7 +361,7 @@ func (c *STS) AssumeRoleWithSAMLRequest(input *AssumeRoleWithSAMLInput) (req *re // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating -// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithSAML @@ -385,7 +391,7 @@ const opAssumeRoleWithWebIdentity = "AssumeRoleWithWebIdentity" // AssumeRoleWithWebIdentityRequest generates a "aws/request.Request" representing the // client's request for the AssumeRoleWithWebIdentity operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -419,42 +425,41 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI output = &AssumeRoleWithWebIdentityOutput{} req = c.newRequest(op, input, output) - req.Config.Credentials = credentials.AnonymousCredentials return } // AssumeRoleWithWebIdentity API operation for AWS Security Token Service. // // Returns a set of temporary security credentials for users who have been authenticated -// in a mobile or web application with a web identity provider. Example providers -// include Amazon Cognito, Login with Amazon, Facebook, Google, or any OpenID -// Connect-compatible identity provider. +// in a mobile or web application with a web identity provider, such as Amazon +// Cognito, Login with Amazon, Facebook, Google, or any OpenID Connect-compatible +// identity provider. // // For mobile applications, we recommend that you use Amazon Cognito. You can -// use Amazon Cognito with the AWS SDK for iOS Developer Guide (http://aws.amazon.com/sdkforios/) -// and the AWS SDK for Android Developer Guide (http://aws.amazon.com/sdkforandroid/) -// to uniquely identify a user. You can also supply the user with a consistent -// identity throughout the lifetime of an application. +// use Amazon Cognito with the AWS SDK for iOS (http://aws.amazon.com/sdkforios/) +// and the AWS SDK for Android (http://aws.amazon.com/sdkforandroid/) to uniquely +// identify a user and supply the user with a consistent identity throughout +// the lifetime of an application. // -// To learn more about Amazon Cognito, see Amazon Cognito Overview (https://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840) -// in AWS SDK for Android Developer Guide and Amazon Cognito Overview (https://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664) +// To learn more about Amazon Cognito, see Amazon Cognito Overview (http://docs.aws.amazon.com/mobile/sdkforandroid/developerguide/cognito-auth.html#d0e840) +// in the AWS SDK for Android Developer Guide guide and Amazon Cognito Overview +// (http://docs.aws.amazon.com/mobile/sdkforios/developerguide/cognito-auth.html#d0e664) // in the AWS SDK for iOS Developer Guide. // // Calling AssumeRoleWithWebIdentity does not require the use of AWS security // credentials. Therefore, you can distribute an application (for example, on // mobile devices) that requests temporary security credentials without including -// long-term AWS credentials in the application. You also don't need to deploy -// server-based proxy services that use long-term AWS credentials. Instead, -// the identity of the caller is validated by using a token from the web identity -// provider. For a comparison of AssumeRoleWithWebIdentity with the other API -// operations that produce temporary credentials, see Requesting Temporary Security -// Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) -// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) +// long-term AWS credentials in the application, and without deploying server-based +// proxy services that use long-term AWS credentials. Instead, the identity +// of the caller is validated by using a token from the web identity provider. +// For a comparison of AssumeRoleWithWebIdentity with the other APIs that produce +// temporary credentials, see Requesting Temporary Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) +// and Comparing the AWS STS APIs (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) // in the IAM User Guide. // // The temporary security credentials returned by this API consist of an access // key ID, a secret access key, and a security token. Applications can use these -// temporary security credentials to sign calls to AWS service API operations. +// temporary security credentials to sign calls to AWS service APIs. // // By default, the temporary security credentials created by AssumeRoleWithWebIdentity // last for one hour. However, you can use the optional DurationSeconds parameter @@ -462,29 +467,29 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI // seconds (15 minutes) up to the maximum session duration setting for the role. // This setting can have a value from 1 hour to 12 hours. To learn how to view // the maximum value for your role, see View the Maximum Session Duration Setting -// for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) +// for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. The maximum session duration limit applies when you -// use the AssumeRole* API operations or the assume-role* CLI commands. However -// the limit does not apply when you use those operations to create a console -// URL. For more information, see Using IAM Roles (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) +// use the AssumeRole* API operations or the assume-role* CLI operations but +// does not apply when you use those operations to create a console URL. For +// more information, see Using IAM Roles (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html) // in the IAM User Guide. // // The temporary security credentials created by AssumeRoleWithWebIdentity can // be used to make API calls to any AWS service with the following exception: -// you cannot call the STS GetFederationToken or GetSessionToken API operations. +// you cannot call the STS service's GetFederationToken or GetSessionToken APIs. // -// (Optional) You can pass inline or managed session policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) -// to this operation. You can pass a single JSON policy document to use as an -// inline session policy. You can also specify up to 10 managed policies to -// use as managed session policies. The plain text that you use for both inline -// and managed session policies shouldn't exceed 2048 characters. Passing policies -// to this operation returns new temporary credentials. The resulting session's -// permissions are the intersection of the role's identity-based policy and -// the session policies. You can use the role's temporary credentials in subsequent -// AWS API calls to access resources in the account that owns the role. You -// cannot use session policies to grant more permissions than those allowed -// by the identity-based policy of the role that is being assumed. For more -// information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) +// Optionally, you can pass an IAM access policy to this operation. If you choose +// not to pass a policy, the temporary security credentials that are returned +// by the operation have the permissions that are defined in the access policy +// of the role that is being assumed. If you pass a policy to this operation, +// the temporary security credentials that are returned by the operation have +// the permissions that are allowed by both the access policy of the role that +// is being assumed, and the policy that you pass. This gives you a way to further +// restrict the permissions for the resulting temporary security credentials. +// You cannot use the passed policy to grant permissions that are in excess +// of those allowed by the access policy of the role that is being assumed. +// For more information, see Permissions for AssumeRole, AssumeRoleWithSAML, +// and AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // // Before your application can call AssumeRoleWithWebIdentity, you must have @@ -503,19 +508,21 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI // For more information about how to use web identity federation and the AssumeRoleWithWebIdentity // API, see the following resources: // -// * Using Web Identity Federation API Operations for Mobile Apps (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html) -// and Federation Through a Web-based Identity Provider (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity). +// * Using Web Identity Federation APIs for Mobile Apps (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_oidc_manual.html) +// and Federation Through a Web-based Identity Provider (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity). // -// * Web Identity Federation Playground (https://web-identity-federation-playground.s3.amazonaws.com/index.html). -// Walk through the process of authenticating through Login with Amazon, -// Facebook, or Google, getting temporary security credentials, and then -// using those credentials to make a request to AWS. // -// * AWS SDK for iOS Developer Guide (http://aws.amazon.com/sdkforios/) and -// AWS SDK for Android Developer Guide (http://aws.amazon.com/sdkforandroid/). -// These toolkits contain sample apps that show how to invoke the identity -// providers, and then how to use the information from these providers to -// get and use temporary security credentials. +// * Web Identity Federation Playground (https://web-identity-federation-playground.s3.amazonaws.com/index.html). +// This interactive website lets you walk through the process of authenticating +// via Login with Amazon, Facebook, or Google, getting temporary security +// credentials, and then using those credentials to make a request to AWS. +// +// +// * AWS SDK for iOS (http://aws.amazon.com/sdkforios/) and AWS SDK for Android +// (http://aws.amazon.com/sdkforandroid/). These toolkits contain sample +// apps that show how to invoke the identity providers, and then how to use +// the information from these providers to get and use temporary security +// credentials. // // * Web Identity Federation with Mobile Applications (http://aws.amazon.com/articles/web-identity-federation-with-mobile-applications). // This article discusses web identity federation and shows an example of @@ -565,7 +572,7 @@ func (c *STS) AssumeRoleWithWebIdentityRequest(input *AssumeRoleWithWebIdentityI // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating -// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/AssumeRoleWithWebIdentity @@ -595,7 +602,7 @@ const opDecodeAuthorizationMessage = "DecodeAuthorizationMessage" // DecodeAuthorizationMessageRequest generates a "aws/request.Request" representing the // client's request for the DecodeAuthorizationMessage operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -637,17 +644,17 @@ func (c *STS) DecodeAuthorizationMessageRequest(input *DecodeAuthorizationMessag // Decodes additional information about the authorization status of a request // from an encoded message returned in response to an AWS request. // -// For example, if a user is not authorized to perform an operation that he -// or she has requested, the request returns a Client.UnauthorizedOperation -// response (an HTTP 403 response). Some AWS operations additionally return -// an encoded message that can provide details about this authorization failure. +// For example, if a user is not authorized to perform an action that he or +// she has requested, the request returns a Client.UnauthorizedOperation response +// (an HTTP 403 response). Some AWS actions additionally return an encoded message +// that can provide details about this authorization failure. // -// Only certain AWS operations return an encoded authorization message. The -// documentation for an individual operation indicates whether that operation -// returns an encoded message in addition to returning an HTTP code. +// Only certain AWS actions return an encoded authorization message. The documentation +// for an individual action indicates whether that action returns an encoded +// message in addition to returning an HTTP code. // // The message is encoded because the details of the authorization status can -// constitute privileged information that the user who requested the operation +// constitute privileged information that the user who requested the action // should not see. To decode an authorization status message, a user must be // granted permissions via an IAM policy to request the DecodeAuthorizationMessage // (sts:DecodeAuthorizationMessage) action. @@ -656,7 +663,7 @@ func (c *STS) DecodeAuthorizationMessageRequest(input *DecodeAuthorizationMessag // // * Whether the request was denied due to an explicit deny or due to the // absence of an explicit allow. For more information, see Determining Whether -// a Request is Allowed or Denied (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow) +// a Request is Allowed or Denied (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html#policy-eval-denyallow) // in the IAM User Guide. // // * The principal who made the request. @@ -707,7 +714,7 @@ const opGetCallerIdentity = "GetCallerIdentity" // GetCallerIdentityRequest generates a "aws/request.Request" representing the // client's request for the GetCallerIdentity operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -782,7 +789,7 @@ const opGetFederationToken = "GetFederationToken" // GetFederationTokenRequest generates a "aws/request.Request" representing the // client's request for the GetFederationToken operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -824,65 +831,81 @@ func (c *STS) GetFederationTokenRequest(input *GetFederationTokenInput) (req *re // Returns a set of temporary security credentials (consisting of an access // key ID, a secret access key, and a security token) for a federated user. // A typical use is in a proxy application that gets temporary security credentials -// on behalf of distributed applications inside a corporate network. You must -// call the GetFederationToken operation using the long-term security credentials -// of an IAM user. As a result, this call is appropriate in contexts where those +// on behalf of distributed applications inside a corporate network. Because +// you must call the GetFederationToken action using the long-term security +// credentials of an IAM user, this call is appropriate in contexts where those // credentials can be safely stored, usually in a server-based application. -// For a comparison of GetFederationToken with the other API operations that -// produce temporary credentials, see Requesting Temporary Security Credentials -// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) -// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) +// For a comparison of GetFederationToken with the other APIs that produce temporary +// credentials, see Requesting Temporary Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) +// and Comparing the AWS STS APIs (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) // in the IAM User Guide. // -// You can create a mobile-based or browser-based app that can authenticate +// If you are creating a mobile-based or browser-based app that can authenticate // users using a web identity provider like Login with Amazon, Facebook, Google, -// or an OpenID Connect-compatible identity provider. In this case, we recommend -// that you use Amazon Cognito (http://aws.amazon.com/cognito/) or AssumeRoleWithWebIdentity. +// or an OpenID Connect-compatible identity provider, we recommend that you +// use Amazon Cognito (http://aws.amazon.com/cognito/) or AssumeRoleWithWebIdentity. // For more information, see Federation Through a Web-based Identity Provider -// (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity). +// (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_assumerolewithwebidentity). // -// You can also call GetFederationToken using the security credentials of an -// AWS account root user, but we do not recommend it. Instead, we recommend -// that you create an IAM user for the purpose of the proxy application. Then -// attach a policy to the IAM user that limits federated users to only the actions -// and resources that they need to access. For more information, see IAM Best -// Practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html) +// The GetFederationToken action must be called by using the long-term AWS security +// credentials of an IAM user. You can also call GetFederationToken using the +// security credentials of an AWS root account, but we do not recommended it. +// Instead, we recommend that you create an IAM user for the purpose of the +// proxy application and then attach a policy to the IAM user that limits federated +// users to only the actions and resources that they need access to. For more +// information, see IAM Best Practices (http://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html) // in the IAM User Guide. // -// The temporary credentials are valid for the specified duration, from 900 -// seconds (15 minutes) up to a maximum of 129,600 seconds (36 hours). The default -// is 43,200 seconds (12 hours). Temporary credentials that are obtained by -// using AWS account root user credentials have a maximum duration of 3,600 -// seconds (1 hour). +// The temporary security credentials that are obtained by using the long-term +// credentials of an IAM user are valid for the specified duration, from 900 +// seconds (15 minutes) up to a maximium of 129600 seconds (36 hours). The default +// is 43200 seconds (12 hours). Temporary credentials that are obtained by using +// AWS root account credentials have a maximum duration of 3600 seconds (1 hour). // // The temporary security credentials created by GetFederationToken can be used // to make API calls to any AWS service with the following exceptions: // -// * You cannot use these credentials to call any IAM API operations. +// * You cannot use these credentials to call any IAM APIs. // -// * You cannot call any STS API operations except GetCallerIdentity. +// * You cannot call any STS APIs except GetCallerIdentity. // // Permissions // -// You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) -// to this operation. You can pass a single JSON policy document to use as an -// inline session policy. You can also specify up to 10 managed policies to -// use as managed session policies. The plain text that you use for both inline -// and managed session policies shouldn't exceed 2048 characters. +// The permissions for the temporary security credentials returned by GetFederationToken +// are determined by a combination of the following: // -// Though the session policy parameters are optional, if you do not pass a policy, -// then the resulting federated user session has no permissions. The only exception -// is when the credentials are used to access a resource that has a resource-based -// policy that specifically references the federated user session in the Principal -// element of the policy. When you pass session policies, the session permissions -// are the intersection of the IAM user policies and the session policies that -// you pass. This gives you a way to further restrict the permissions for a -// federated user. You cannot use session policies to grant more permissions -// than those that are defined in the permissions policy of the IAM user. For -// more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) -// in the IAM User Guide. For information about using GetFederationToken to -// create temporary security credentials, see GetFederationToken—Federation -// Through a Custom Identity Broker (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken). +// * The policy or policies that are attached to the IAM user whose credentials +// are used to call GetFederationToken. +// +// * The policy that is passed as a parameter in the call. +// +// The passed policy is attached to the temporary security credentials that +// result from the GetFederationToken API call--that is, to the federated user. +// When the federated user makes an AWS request, AWS evaluates the policy attached +// to the federated user in combination with the policy or policies attached +// to the IAM user whose credentials were used to call GetFederationToken. AWS +// allows the federated user's request only when both the federated user and +// the IAM user are explicitly allowed to perform the requested action. The +// passed policy cannot grant more permissions than those that are defined in +// the IAM user policy. +// +// A typical use case is that the permissions of the IAM user whose credentials +// are used to call GetFederationToken are designed to allow access to all the +// actions and resources that any federated user will need. Then, for individual +// users, you pass a policy to the operation that scopes down the permissions +// to a level that's appropriate to that individual user, using a policy that +// allows only a subset of permissions that are granted to the IAM user. +// +// If you do not pass a policy, the resulting temporary security credentials +// have no effective permissions. The only exception is when the temporary security +// credentials are used to access a resource that has a resource-based policy +// that specifically allows the federated user to access the resource. +// +// For more information about how permissions work, see Permissions for GetFederationToken +// (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_getfederationtoken.html). +// For information about using GetFederationToken to create temporary security +// credentials, see GetFederationToken—Federation Through a Custom Identity +// Broker (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getfederationtoken). // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about @@ -905,7 +928,7 @@ func (c *STS) GetFederationTokenRequest(input *GetFederationTokenInput) (req *re // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating -// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetFederationToken @@ -935,7 +958,7 @@ const opGetSessionToken = "GetSessionToken" // GetSessionTokenRequest generates a "aws/request.Request" representing the // client's request for the GetSessionToken operation. The "output" return // value will be populated with the request's response once the request completes -// successfully. +// successfuly. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. @@ -977,47 +1000,48 @@ func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request. // Returns a set of temporary credentials for an AWS account or IAM user. The // credentials consist of an access key ID, a secret access key, and a security // token. Typically, you use GetSessionToken if you want to use MFA to protect -// programmatic calls to specific AWS API operations like Amazon EC2 StopInstances. -// MFA-enabled IAM users would need to call GetSessionToken and submit an MFA -// code that is associated with their MFA device. Using the temporary security -// credentials that are returned from the call, IAM users can then make programmatic -// calls to API operations that require MFA authentication. If you do not supply -// a correct MFA code, then the API returns an access denied error. For a comparison -// of GetSessionToken with the other API operations that produce temporary credentials, -// see Requesting Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) -// and Comparing the AWS STS API operations (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) +// programmatic calls to specific AWS APIs like Amazon EC2 StopInstances. MFA-enabled +// IAM users would need to call GetSessionToken and submit an MFA code that +// is associated with their MFA device. Using the temporary security credentials +// that are returned from the call, IAM users can then make programmatic calls +// to APIs that require MFA authentication. If you do not supply a correct MFA +// code, then the API returns an access denied error. For a comparison of GetSessionToken +// with the other APIs that produce temporary credentials, see Requesting Temporary +// Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html) +// and Comparing the AWS STS APIs (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#stsapi_comparison) // in the IAM User Guide. // -// The GetSessionToken operation must be called by using the long-term AWS security -// credentials of the AWS account root user or an IAM user. Credentials that -// are created by IAM users are valid for the duration that you specify. This -// duration can range from 900 seconds (15 minutes) up to a maximum of 129,600 -// seconds (36 hours), with a default of 43,200 seconds (12 hours). Credentials -// based on account credentials can range from 900 seconds (15 minutes) up to -// 3,600 seconds (1 hour), with a default of 1 hour. +// The GetSessionToken action must be called by using the long-term AWS security +// credentials of the AWS account or an IAM user. Credentials that are created +// by IAM users are valid for the duration that you specify, from 900 seconds +// (15 minutes) up to a maximum of 129600 seconds (36 hours), with a default +// of 43200 seconds (12 hours); credentials that are created by using account +// credentials can range from 900 seconds (15 minutes) up to a maximum of 3600 +// seconds (1 hour), with a default of 1 hour. // // The temporary security credentials created by GetSessionToken can be used // to make API calls to any AWS service with the following exceptions: // -// * You cannot call any IAM API operations unless MFA authentication information -// is included in the request. +// * You cannot call any IAM APIs unless MFA authentication information is +// included in the request. // -// * You cannot call any STS API except AssumeRole or GetCallerIdentity. +// * You cannot call any STS API exceptAssumeRole or GetCallerIdentity. // -// We recommend that you do not call GetSessionToken with AWS account root user -// credentials. Instead, follow our best practices (https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users) +// We recommend that you do not call GetSessionToken with root account credentials. +// Instead, follow our best practices (http://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html#create-iam-users) // by creating one or more IAM users, giving them the necessary permissions, // and using IAM users for everyday interaction with AWS. // -// The credentials that are returned by GetSessionToken are based on permissions -// associated with the user whose credentials were used to call the operation. -// If GetSessionToken is called using AWS account root user credentials, the -// temporary credentials have root user permissions. Similarly, if GetSessionToken -// is called using the credentials of an IAM user, the temporary credentials -// have the same permissions as the IAM user. +// The permissions associated with the temporary security credentials returned +// by GetSessionToken are based on the permissions associated with account or +// IAM user whose credentials are used to call the action. If GetSessionToken +// is called using root account credentials, the temporary credentials have +// root account permissions. Similarly, if GetSessionToken is called using the +// credentials of an IAM user, the temporary credentials have the same permissions +// as the IAM user. // // For more information about using GetSessionToken to create temporary credentials, -// go to Temporary Credentials for Users in Untrusted Environments (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken) +// go to Temporary Credentials for Users in Untrusted Environments (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_request.html#api_getsessiontoken) // in the IAM User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions @@ -1032,7 +1056,7 @@ func (c *STS) GetSessionTokenRequest(input *GetSessionTokenInput) (req *request. // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating -// and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // // See also, https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15/GetSessionToken @@ -1067,7 +1091,7 @@ type AssumeRoleInput struct { // a session duration of 12 hours, but your administrator set the maximum session // duration to 6 hours, your operation fails. To learn how to view the maximum // value for your role, see View the Maximum Session Duration Setting for a - // Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. // // By default, the value is set to 3600 seconds. @@ -1077,77 +1101,51 @@ type AssumeRoleInput struct { // to the federation endpoint for a console sign-in token takes a SessionDuration // parameter that specifies the maximum length of the console session. For more // information, see Creating a URL that Enables Federated Users to Access the - // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` - // A unique identifier that might be required when you assume a role in another - // account. If the administrator of the account to which the role belongs provided - // you with an external ID, then provide that value in the ExternalId parameter. - // This value can be any string, such as a passphrase or account number. A cross-account - // role is usually set up to trust everyone in an account. Therefore, the administrator - // of the trusting account might send an external ID to the administrator of - // the trusted account. That way, only someone with the ID can assume the role, - // rather than everyone in the account. For more information about the external - // ID, see How to Use an External ID When Granting Access to Your AWS Resources - // to a Third Party (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html) + // A unique identifier that is used by third parties when assuming roles in + // their customers' accounts. For each role that the third party can assume, + // they should instruct their customers to ensure the role's trust policy checks + // for the external ID that the third party generated. Each time the third party + // assumes the role, they should pass the customer's external ID. The external + // ID is useful in order to help third parties bind a role to the customer who + // created it. For more information about the external ID, see How to Use an + // External ID When Granting Access to Your AWS Resources to a Third Party (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html) // in the IAM User Guide. // - // The regex used to validate this parameter is a string of characters consisting + // The regex used to validated this parameter is a string of characters consisting // of upper- and lower-case alphanumeric characters with no spaces. You can // also include underscores or any of the following characters: =,.@:/- ExternalId *string `min:"2" type:"string"` - // An IAM policy in JSON format that you want to use as an inline session policy. + // An IAM policy in JSON format. // - // This parameter is optional. Passing policies to this operation returns new - // temporary credentials. The resulting session's permissions are the intersection - // of the role's identity-based policy and the session policies. You can use - // the role's temporary credentials in subsequent AWS API calls to access resources - // in the account that owns the role. You cannot use session policies to grant - // more permissions than those allowed by the identity-based policy of the role - // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) + // This parameter is optional. If you pass a policy, the temporary security + // credentials that are returned by the operation have the permissions that + // are allowed by both (the intersection of) the access policy of the role that + // is being assumed, and the policy that you pass. This gives you a way to further + // restrict the permissions for the resulting temporary security credentials. + // You cannot use the passed policy to grant permissions that are in excess + // of those allowed by the access policy of the role that is being assumed. + // For more information, see Permissions for AssumeRole, AssumeRoleWithSAML, + // and AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // - // The plain text that you use for both inline and managed session policies - // shouldn't exceed 2048 characters. The JSON policy characters can be any ASCII - // character from the space character to the end of the valid character list - // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A), + // The format for this parameter, as described by its regex pattern, is a string + // of characters up to 2048 characters in length. The characters can be any + // ASCII character from the space character to the end of the valid character + // list (\u0020-\u00FF). It can also include the tab (\u0009), linefeed (\u000A), // and carriage return (\u000D) characters. // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. + // The policy plain text must be 2048 bytes or shorter. However, an internal + // conversion compresses it into a packed binary format with a separate limit. + // The PackedPolicySize response element indicates by percentage how close to + // the upper size limit the policy is, with 100% equaling the maximum allowed + // size. Policy *string `min:"1" type:"string"` - // The Amazon Resource Names (ARNs) of the IAM managed policies that you want - // to use as managed session policies. The policies must exist in the same account - // as the role. - // - // This parameter is optional. You can provide up to 10 managed policy ARNs. - // However, the plain text that you use for both inline and managed session - // policies shouldn't exceed 2048 characters. For more information about ARNs, - // see Amazon Resource Names (ARNs) and AWS Service Namespaces (general/latest/gr/aws-arns-and-namespaces.html) - // in the AWS General Reference. - // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. - // - // Passing policies to this operation returns new temporary credentials. The - // resulting session's permissions are the intersection of the role's identity-based - // policy and the session policies. You can use the role's temporary credentials - // in subsequent AWS API calls to access resources in the account that owns - // the role. You cannot use session policies to grant more permissions than - // those allowed by the identity-based policy of the role that is being assumed. - // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // in the IAM User Guide. - PolicyArns []*PolicyDescriptorType `type:"list"` - // The Amazon Resource Name (ARN) of the role to assume. // // RoleArn is a required field @@ -1160,8 +1158,8 @@ type AssumeRoleInput struct { // scenarios, the role session name is visible to, and can be logged by the // account that owns the role. The role session name is also used in the ARN // of the assumed role principal. This means that subsequent cross-account API - // requests that use the temporary security credentials will expose the role - // session name to the external account in their AWS CloudTrail logs. + // requests using the temporary security credentials will expose the role session + // name to the external account in their CloudTrail logs. // // The regex used to validate this parameter is a string of characters consisting // of upper- and lower-case alphanumeric characters with no spaces. You can @@ -1231,16 +1229,6 @@ func (s *AssumeRoleInput) Validate() error { if s.TokenCode != nil && len(*s.TokenCode) < 6 { invalidParams.Add(request.NewErrParamMinLen("TokenCode", 6)) } - if s.PolicyArns != nil { - for i, v := range s.PolicyArns { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -1266,12 +1254,6 @@ func (s *AssumeRoleInput) SetPolicy(v string) *AssumeRoleInput { return s } -// SetPolicyArns sets the PolicyArns field's value. -func (s *AssumeRoleInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleInput { - s.PolicyArns = v - return s -} - // SetRoleArn sets the RoleArn field's value. func (s *AssumeRoleInput) SetRoleArn(v string) *AssumeRoleInput { s.RoleArn = &v @@ -1311,8 +1293,10 @@ type AssumeRoleOutput struct { // The temporary security credentials, which include an access key ID, a secret // access key, and a security (or session) token. // - // The size of the security token that STS API operations return is not fixed. - // We strongly recommend that you make no assumptions about the maximum size. + // Note: The size of the security token that STS APIs return is not fixed. We + // strongly recommend that you make no assumptions about the maximum size. As + // of this writing, the typical size is less than 4096 bytes, but that can vary. + // Also, future updates to AWS might require larger sizes. Credentials *Credentials `type:"structure"` // A percentage value that indicates the size of the policy in packed form. @@ -1362,7 +1346,7 @@ type AssumeRoleWithSAMLInput struct { // specify a session duration of 12 hours, but your administrator set the maximum // session duration to 6 hours, your operation fails. To learn how to view the // maximum value for your role, see View the Maximum Session Duration Setting - // for a Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // for a Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. // // By default, the value is set to 3600 seconds. @@ -1372,60 +1356,36 @@ type AssumeRoleWithSAMLInput struct { // to the federation endpoint for a console sign-in token takes a SessionDuration // parameter that specifies the maximum length of the console session. For more // information, see Creating a URL that Enables Federated Users to Access the - // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` - // An IAM policy in JSON format that you want to use as an inline session policy. + // An IAM policy in JSON format. // - // This parameter is optional. Passing policies to this operation returns new - // temporary credentials. The resulting session's permissions are the intersection - // of the role's identity-based policy and the session policies. You can use - // the role's temporary credentials in subsequent AWS API calls to access resources - // in the account that owns the role. You cannot use session policies to grant - // more permissions than those allowed by the identity-based policy of the role - // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) + // The policy parameter is optional. If you pass a policy, the temporary security + // credentials that are returned by the operation have the permissions that + // are allowed by both the access policy of the role that is being assumed, + // and the policy that you pass. This gives you a way to further restrict the + // permissions for the resulting temporary security credentials. You cannot + // use the passed policy to grant permissions that are in excess of those allowed + // by the access policy of the role that is being assumed. For more information, + // Permissions for AssumeRole, AssumeRoleWithSAML, and AssumeRoleWithWebIdentity + // (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // - // The plain text that you use for both inline and managed session policies - // shouldn't exceed 2048 characters. The JSON policy characters can be any ASCII - // character from the space character to the end of the valid character list - // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A), + // The format for this parameter, as described by its regex pattern, is a string + // of characters up to 2048 characters in length. The characters can be any + // ASCII character from the space character to the end of the valid character + // list (\u0020-\u00FF). It can also include the tab (\u0009), linefeed (\u000A), // and carriage return (\u000D) characters. // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. + // The policy plain text must be 2048 bytes or shorter. However, an internal + // conversion compresses it into a packed binary format with a separate limit. + // The PackedPolicySize response element indicates by percentage how close to + // the upper size limit the policy is, with 100% equaling the maximum allowed + // size. Policy *string `min:"1" type:"string"` - // The Amazon Resource Names (ARNs) of the IAM managed policies that you want - // to use as managed session policies. The policies must exist in the same account - // as the role. - // - // This parameter is optional. You can provide up to 10 managed policy ARNs. - // However, the plain text that you use for both inline and managed session - // policies shouldn't exceed 2048 characters. For more information about ARNs, - // see Amazon Resource Names (ARNs) and AWS Service Namespaces (general/latest/gr/aws-arns-and-namespaces.html) - // in the AWS General Reference. - // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. - // - // Passing policies to this operation returns new temporary credentials. The - // resulting session's permissions are the intersection of the role's identity-based - // policy and the session policies. You can use the role's temporary credentials - // in subsequent AWS API calls to access resources in the account that owns - // the role. You cannot use session policies to grant more permissions than - // those allowed by the identity-based policy of the role that is being assumed. - // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // in the IAM User Guide. - PolicyArns []*PolicyDescriptorType `type:"list"` - // The Amazon Resource Name (ARN) of the SAML provider in IAM that describes // the IdP. // @@ -1439,8 +1399,8 @@ type AssumeRoleWithSAMLInput struct { // The base-64 encoded SAML authentication response provided by the IdP. // - // For more information, see Configuring a Relying Party and Adding Claims (https://docs.aws.amazon.com/IAM/latest/UserGuide/create-role-saml-IdP-tasks.html) - // in the IAM User Guide. + // For more information, see Configuring a Relying Party and Adding Claims (http://docs.aws.amazon.com/IAM/latest/UserGuide/create-role-saml-IdP-tasks.html) + // in the Using IAM guide. // // SAMLAssertion is a required field SAMLAssertion *string `min:"4" type:"string" required:"true"` @@ -1483,16 +1443,6 @@ func (s *AssumeRoleWithSAMLInput) Validate() error { if s.SAMLAssertion != nil && len(*s.SAMLAssertion) < 4 { invalidParams.Add(request.NewErrParamMinLen("SAMLAssertion", 4)) } - if s.PolicyArns != nil { - for i, v := range s.PolicyArns { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -1512,12 +1462,6 @@ func (s *AssumeRoleWithSAMLInput) SetPolicy(v string) *AssumeRoleWithSAMLInput { return s } -// SetPolicyArns sets the PolicyArns field's value. -func (s *AssumeRoleWithSAMLInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleWithSAMLInput { - s.PolicyArns = v - return s -} - // SetPrincipalArn sets the PrincipalArn field's value. func (s *AssumeRoleWithSAMLInput) SetPrincipalArn(v string) *AssumeRoleWithSAMLInput { s.PrincipalArn = &v @@ -1552,8 +1496,10 @@ type AssumeRoleWithSAMLOutput struct { // The temporary security credentials, which include an access key ID, a secret // access key, and a security (or session) token. // - // The size of the security token that STS API operations return is not fixed. - // We strongly recommend that you make no assumptions about the maximum size. + // Note: The size of the security token that STS APIs return is not fixed. We + // strongly recommend that you make no assumptions about the maximum size. As + // of this writing, the typical size is less than 4096 bytes, but that can vary. + // Also, future updates to AWS might require larger sizes. Credentials *Credentials `type:"structure"` // The value of the Issuer element of the SAML assertion. @@ -1657,7 +1603,7 @@ type AssumeRoleWithWebIdentityInput struct { // a session duration of 12 hours, but your administrator set the maximum session // duration to 6 hours, your operation fails. To learn how to view the maximum // value for your role, see View the Maximum Session Duration Setting for a - // Role (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) + // Role (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use.html#id_roles_use_view-role-max-session) // in the IAM User Guide. // // By default, the value is set to 3600 seconds. @@ -1667,60 +1613,35 @@ type AssumeRoleWithWebIdentityInput struct { // to the federation endpoint for a console sign-in token takes a SessionDuration // parameter that specifies the maximum length of the console session. For more // information, see Creating a URL that Enables Federated Users to Access the - // AWS Management Console (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) + // AWS Management Console (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_enable-console-custom-url.html) // in the IAM User Guide. DurationSeconds *int64 `min:"900" type:"integer"` - // An IAM policy in JSON format that you want to use as an inline session policy. + // An IAM policy in JSON format. // - // This parameter is optional. Passing policies to this operation returns new - // temporary credentials. The resulting session's permissions are the intersection - // of the role's identity-based policy and the session policies. You can use - // the role's temporary credentials in subsequent AWS API calls to access resources - // in the account that owns the role. You cannot use session policies to grant - // more permissions than those allowed by the identity-based policy of the role - // that is being assumed. For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) + // The policy parameter is optional. If you pass a policy, the temporary security + // credentials that are returned by the operation have the permissions that + // are allowed by both the access policy of the role that is being assumed, + // and the policy that you pass. This gives you a way to further restrict the + // permissions for the resulting temporary security credentials. You cannot + // use the passed policy to grant permissions that are in excess of those allowed + // by the access policy of the role that is being assumed. For more information, + // see Permissions for AssumeRoleWithWebIdentity (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_assumerole.html) // in the IAM User Guide. // - // The plain text that you use for both inline and managed session policies - // shouldn't exceed 2048 characters. The JSON policy characters can be any ASCII - // character from the space character to the end of the valid character list - // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A), + // The format for this parameter, as described by its regex pattern, is a string + // of characters up to 2048 characters in length. The characters can be any + // ASCII character from the space character to the end of the valid character + // list (\u0020-\u00FF). It can also include the tab (\u0009), linefeed (\u000A), // and carriage return (\u000D) characters. // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. + // The policy plain text must be 2048 bytes or shorter. However, an internal + // conversion compresses it into a packed binary format with a separate limit. + // The PackedPolicySize response element indicates by percentage how close to + // the upper size limit the policy is, with 100% equaling the maximum allowed + // size. Policy *string `min:"1" type:"string"` - // The Amazon Resource Names (ARNs) of the IAM managed policies that you want - // to use as managed session policies. The policies must exist in the same account - // as the role. - // - // This parameter is optional. You can provide up to 10 managed policy ARNs. - // However, the plain text that you use for both inline and managed session - // policies shouldn't exceed 2048 characters. For more information about ARNs, - // see Amazon Resource Names (ARNs) and AWS Service Namespaces (general/latest/gr/aws-arns-and-namespaces.html) - // in the AWS General Reference. - // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. - // - // Passing policies to this operation returns new temporary credentials. The - // resulting session's permissions are the intersection of the role's identity-based - // policy and the session policies. You can use the role's temporary credentials - // in subsequent AWS API calls to access resources in the account that owns - // the role. You cannot use session policies to grant more permissions than - // those allowed by the identity-based policy of the role that is being assumed. - // For more information, see Session Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // in the IAM User Guide. - PolicyArns []*PolicyDescriptorType `type:"list"` - // The fully qualified host component of the domain name of the identity provider. // // Specify this value only for OAuth 2.0 access tokens. Currently www.amazon.com @@ -1797,16 +1718,6 @@ func (s *AssumeRoleWithWebIdentityInput) Validate() error { if s.WebIdentityToken != nil && len(*s.WebIdentityToken) < 4 { invalidParams.Add(request.NewErrParamMinLen("WebIdentityToken", 4)) } - if s.PolicyArns != nil { - for i, v := range s.PolicyArns { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -1826,12 +1737,6 @@ func (s *AssumeRoleWithWebIdentityInput) SetPolicy(v string) *AssumeRoleWithWebI return s } -// SetPolicyArns sets the PolicyArns field's value. -func (s *AssumeRoleWithWebIdentityInput) SetPolicyArns(v []*PolicyDescriptorType) *AssumeRoleWithWebIdentityInput { - s.PolicyArns = v - return s -} - // SetProviderId sets the ProviderId field's value. func (s *AssumeRoleWithWebIdentityInput) SetProviderId(v string) *AssumeRoleWithWebIdentityInput { s.ProviderId = &v @@ -1876,8 +1781,10 @@ type AssumeRoleWithWebIdentityOutput struct { // The temporary security credentials, which include an access key ID, a secret // access key, and a security token. // - // The size of the security token that STS API operations return is not fixed. - // We strongly recommend that you make no assumptions about the maximum size. + // Note: The size of the security token that STS APIs return is not fixed. We + // strongly recommend that you make no assumptions about the maximum size. As + // of this writing, the typical size is less than 4096 bytes, but that can vary. + // Also, future updates to AWS might require larger sizes. Credentials *Credentials `type:"structure"` // A percentage value that indicates the size of the policy in packed form. @@ -1886,7 +1793,7 @@ type AssumeRoleWithWebIdentityOutput struct { PackedPolicySize *int64 `type:"integer"` // The issuing authority of the web identity token presented. For OpenID Connect - // ID tokens, this contains the value of the iss field. For OAuth 2.0 access + // ID Tokens this contains the value of the iss field. For OAuth 2.0 access // tokens, this contains the value of the ProviderId parameter that was passed // in the AssumeRoleWithWebIdentity request. Provider *string `type:"string"` @@ -1953,7 +1860,7 @@ type AssumedRoleUser struct { // The ARN of the temporary security credentials that are returned from the // AssumeRole action. For more information about ARNs and how to use them in - // policies, see IAM Identifiers (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) + // policies, see IAM Identifiers (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) // in Using IAM. // // Arn is a required field @@ -2121,7 +2028,7 @@ type FederatedUser struct { // The ARN that specifies the federated user that is associated with the credentials. // For more information about ARNs and how to use them in policies, see IAM - // Identifiers (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) + // Identifiers (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html) // in Using IAM. // // Arn is a required field @@ -2183,8 +2090,8 @@ type GetCallerIdentityOutput struct { Arn *string `min:"20" type:"string"` // The unique identifier of the calling entity. The exact value depends on the - // type of entity that is making the call. The values returned are those listed - // in the aws:userid column in the Principal table (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_variables.html#principaltable) + // type of entity making the call. The values returned are those listed in the + // aws:userid column in the Principal table (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_variables.html#principaltable) // found on the Policy Variables reference page in the IAM User Guide. UserId *string `type:"string"` } @@ -2221,11 +2128,12 @@ type GetFederationTokenInput struct { _ struct{} `type:"structure"` // The duration, in seconds, that the session should last. Acceptable durations - // for federation sessions range from 900 seconds (15 minutes) to 129,600 seconds - // (36 hours), with 43,200 seconds (12 hours) as the default. Sessions obtained - // using AWS account root user credentials are restricted to a maximum of 3,600 + // for federation sessions range from 900 seconds (15 minutes) to 129600 seconds + // (36 hours), with 43200 seconds (12 hours) as the default. Sessions obtained + // using AWS account (root) credentials are restricted to a maximum of 3600 // seconds (one hour). If the specified duration is longer than one hour, the - // session obtained by using root user credentials defaults to one hour. + // session obtained by using AWS account (root) credentials defaults to one + // hour. DurationSeconds *int64 `min:"900" type:"integer"` // The name of the federated user. The name is used as an identifier for the @@ -2240,73 +2148,36 @@ type GetFederationTokenInput struct { // Name is a required field Name *string `min:"2" type:"string" required:"true"` - // An IAM policy in JSON format that you want to use as an inline session policy. + // An IAM policy in JSON format that is passed with the GetFederationToken call + // and evaluated along with the policy or policies that are attached to the + // IAM user whose credentials are used to call GetFederationToken. The passed + // policy is used to scope down the permissions that are available to the IAM + // user, by allowing only a subset of the permissions that are granted to the + // IAM user. The passed policy cannot grant more permissions than those granted + // to the IAM user. The final permissions for the federated user are the most + // restrictive set based on the intersection of the passed policy and the IAM + // user policy. // - // You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // to this operation. You can pass a single JSON policy document to use as an - // inline session policy. You can also specify up to 10 managed policies to - // use as managed session policies. + // If you do not pass a policy, the resulting temporary security credentials + // have no effective permissions. The only exception is when the temporary security + // credentials are used to access a resource that has a resource-based policy + // that specifically allows the federated user to access the resource. // - // This parameter is optional. However, if you do not pass any session policies, - // then the resulting federated user session has no permissions. The only exception - // is when the credentials are used to access a resource that has a resource-based - // policy that specifically references the federated user session in the Principal - // element of the policy. - // - // When you pass session policies, the session permissions are the intersection - // of the IAM user policies and the session policies that you pass. This gives - // you a way to further restrict the permissions for a federated user. You cannot - // use session policies to grant more permissions than those that are defined - // in the permissions policy of the IAM user. For more information, see Session - // Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // in the IAM User Guide. - // - // The plain text that you use for both inline and managed session policies - // shouldn't exceed 2048 characters. The JSON policy characters can be any ASCII - // character from the space character to the end of the valid character list - // (\u0020 through \u00FF). It can also include the tab (\u0009), linefeed (\u000A), + // The format for this parameter, as described by its regex pattern, is a string + // of characters up to 2048 characters in length. The characters can be any + // ASCII character from the space character to the end of the valid character + // list (\u0020-\u00FF). It can also include the tab (\u0009), linefeed (\u000A), // and carriage return (\u000D) characters. // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. + // The policy plain text must be 2048 bytes or shorter. However, an internal + // conversion compresses it into a packed binary format with a separate limit. + // The PackedPolicySize response element indicates by percentage how close to + // the upper size limit the policy is, with 100% equaling the maximum allowed + // size. + // + // For more information about how permissions work, see Permissions for GetFederationToken + // (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_control-access_getfederationtoken.html). Policy *string `min:"1" type:"string"` - - // The Amazon Resource Names (ARNs) of the IAM managed policies that you want - // to use as a managed session policy. The policies must exist in the same account - // as the IAM user that is requesting federated access. - // - // You must pass an inline or managed session policy (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // to this operation. You can pass a single JSON policy document to use as an - // inline session policy. You can also specify up to 10 managed policies to - // use as managed session policies. The plain text that you use for both inline - // and managed session policies shouldn't exceed 2048 characters. You can provide - // up to 10 managed policy ARNs. For more information about ARNs, see Amazon - // Resource Names (ARNs) and AWS Service Namespaces (general/latest/gr/aws-arns-and-namespaces.html) - // in the AWS General Reference. - // - // This parameter is optional. However, if you do not pass any session policies, - // then the resulting federated user session has no permissions. The only exception - // is when the credentials are used to access a resource that has a resource-based - // policy that specifically references the federated user session in the Principal - // element of the policy. - // - // When you pass session policies, the session permissions are the intersection - // of the IAM user policies and the session policies that you pass. This gives - // you a way to further restrict the permissions for a federated user. You cannot - // use session policies to grant more permissions than those that are defined - // in the permissions policy of the IAM user. For more information, see Session - // Policies (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html#policies_session) - // in the IAM User Guide. - // - // The characters in this parameter count towards the 2048 character session - // policy guideline. However, an AWS conversion compresses the session policies - // into a packed binary format that has a separate limit. This is the enforced - // limit. The PackedPolicySize response element indicates by percentage how - // close the policy is to the upper size limit. - PolicyArns []*PolicyDescriptorType `type:"list"` } // String returns the string representation @@ -2334,16 +2205,6 @@ func (s *GetFederationTokenInput) Validate() error { if s.Policy != nil && len(*s.Policy) < 1 { invalidParams.Add(request.NewErrParamMinLen("Policy", 1)) } - if s.PolicyArns != nil { - for i, v := range s.PolicyArns { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "PolicyArns", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -2369,12 +2230,6 @@ func (s *GetFederationTokenInput) SetPolicy(v string) *GetFederationTokenInput { return s } -// SetPolicyArns sets the PolicyArns field's value. -func (s *GetFederationTokenInput) SetPolicyArns(v []*PolicyDescriptorType) *GetFederationTokenInput { - s.PolicyArns = v - return s -} - // Contains the response to a successful GetFederationToken request, including // temporary AWS credentials that can be used to make AWS requests. type GetFederationTokenOutput struct { @@ -2383,8 +2238,10 @@ type GetFederationTokenOutput struct { // The temporary security credentials, which include an access key ID, a secret // access key, and a security (or session) token. // - // The size of the security token that STS API operations return is not fixed. - // We strongly recommend that you make no assumptions about the maximum size. + // Note: The size of the security token that STS APIs return is not fixed. We + // strongly recommend that you make no assumptions about the maximum size. As + // of this writing, the typical size is less than 4096 bytes, but that can vary. + // Also, future updates to AWS might require larger sizes. Credentials *Credentials `type:"structure"` // Identifiers for the federated user associated with the credentials (such @@ -2431,11 +2288,11 @@ type GetSessionTokenInput struct { _ struct{} `type:"structure"` // The duration, in seconds, that the credentials should remain valid. Acceptable - // durations for IAM user sessions range from 900 seconds (15 minutes) to 129,600 - // seconds (36 hours), with 43,200 seconds (12 hours) as the default. Sessions - // for AWS account owners are restricted to a maximum of 3,600 seconds (one - // hour). If the duration is longer than one hour, the session for AWS account - // owners defaults to one hour. + // durations for IAM user sessions range from 900 seconds (15 minutes) to 129600 + // seconds (36 hours), with 43200 seconds (12 hours) as the default. Sessions + // for AWS account owners are restricted to a maximum of 3600 seconds (one hour). + // If the duration is longer than one hour, the session for AWS account owners + // defaults to one hour. DurationSeconds *int64 `min:"900" type:"integer"` // The identification number of the MFA device that is associated with the IAM @@ -2446,16 +2303,16 @@ type GetSessionTokenInput struct { // You can find the device for an IAM user by going to the AWS Management Console // and viewing the user's security credentials. // - // The regex used to validate this parameter is a string of characters consisting + // The regex used to validated this parameter is a string of characters consisting // of upper- and lower-case alphanumeric characters with no spaces. You can // also include underscores or any of the following characters: =,.@:/- SerialNumber *string `min:"9" type:"string"` // The value provided by the MFA device, if MFA is required. If any policy requires // the IAM user to submit an MFA code, specify this value. If MFA authentication - // is required, the user must provide a code when requesting a set of temporary - // security credentials. A user who fails to provide the code receives an "access - // denied" response when requesting resources that require MFA authentication. + // is required, and the user does not provide a code when requesting a set of + // temporary security credentials, the user will receive an "access denied" + // response when requesting resources that require MFA authentication. // // The format for this parameter, as described by its regex pattern, is a sequence // of six numeric digits. @@ -2517,8 +2374,10 @@ type GetSessionTokenOutput struct { // The temporary security credentials, which include an access key ID, a secret // access key, and a security (or session) token. // - // The size of the security token that STS API operations return is not fixed. - // We strongly recommend that you make no assumptions about the maximum size. + // Note: The size of the security token that STS APIs return is not fixed. We + // strongly recommend that you make no assumptions about the maximum size. As + // of this writing, the typical size is less than 4096 bytes, but that can vary. + // Also, future updates to AWS might require larger sizes. Credentials *Credentials `type:"structure"` } @@ -2537,44 +2396,3 @@ func (s *GetSessionTokenOutput) SetCredentials(v *Credentials) *GetSessionTokenO s.Credentials = v return s } - -// A reference to the IAM managed policy that is passed as a session policy -// for a role session or a federated user session. -type PolicyDescriptorType struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the IAM managed policy to use as a session - // policy for the role. For more information about ARNs, see Amazon Resource - // Names (ARNs) and AWS Service Namespaces (general/latest/gr/aws-arns-and-namespaces.html) - // in the AWS General Reference. - Arn *string `locationName:"arn" min:"20" type:"string"` -} - -// String returns the string representation -func (s PolicyDescriptorType) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation -func (s PolicyDescriptorType) GoString() string { - return s.String() -} - -// Validate inspects the fields of the type to determine if they are valid. -func (s *PolicyDescriptorType) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "PolicyDescriptorType"} - if s.Arn != nil && len(*s.Arn) < 20 { - invalidParams.Add(request.NewErrParamMinLen("Arn", 20)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetArn sets the Arn field's value. -func (s *PolicyDescriptorType) SetArn(v string) *PolicyDescriptorType { - s.Arn = &v - return s -} diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go b/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go new file mode 100644 index 000000000..4010cc7fa --- /dev/null +++ b/vendor/github.com/aws/aws-sdk-go/service/sts/customizations.go @@ -0,0 +1,12 @@ +package sts + +import "github.com/aws/aws-sdk-go/aws/request" + +func init() { + initRequest = func(r *request.Request) { + switch r.Operation.Name { + case opAssumeRoleWithSAML, opAssumeRoleWithWebIdentity: + r.Handlers.Sign.Clear() // these operations are unsigned + } + } +} diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go b/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go index fcb720dca..ef681ab0c 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sts/doc.go @@ -7,14 +7,22 @@ // request temporary, limited-privilege credentials for AWS Identity and Access // Management (IAM) users or for users that you authenticate (federated users). // This guide provides descriptions of the STS API. For more detailed information -// about using this service, go to Temporary Security Credentials (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html). +// about using this service, go to Temporary Security Credentials (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp.html). +// +// As an alternative to using the API, you can use one of the AWS SDKs, which +// consist of libraries and sample code for various programming languages and +// platforms (Java, Ruby, .NET, iOS, Android, etc.). The SDKs provide a convenient +// way to create programmatic access to STS. For example, the SDKs take care +// of cryptographically signing requests, managing errors, and retrying requests +// automatically. For information about the AWS SDKs, including how to download +// and install them, see the Tools for Amazon Web Services page (http://aws.amazon.com/tools/). // // For information about setting up signatures and authorization through the -// API, go to Signing AWS API Requests (https://docs.aws.amazon.com/general/latest/gr/signing_aws_api_requests.html) +// API, go to Signing AWS API Requests (http://docs.aws.amazon.com/general/latest/gr/signing_aws_api_requests.html) // in the AWS General Reference. For general information about the Query API, -// go to Making Query Requests (https://docs.aws.amazon.com/IAM/latest/UserGuide/IAM_UsingQueryAPI.html) +// go to Making Query Requests (http://docs.aws.amazon.com/IAM/latest/UserGuide/IAM_UsingQueryAPI.html) // in Using IAM. For information about using security tokens with other AWS -// products, go to AWS Services That Work with IAM (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_aws-services-that-work-with-iam.html) +// products, go to AWS Services That Work with IAM (http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_aws-services-that-work-with-iam.html) // in the IAM User Guide. // // If you're new to AWS and need additional technical information about a specific @@ -23,38 +31,14 @@ // // Endpoints // -// By default, AWS Security Token Service (STS) is available as a global service, -// and all AWS STS requests go to a single endpoint at https://sts.amazonaws.com. -// Global requests map to the US East (N. Virginia) region. AWS recommends using -// Regional AWS STS endpoints instead of the global endpoint to reduce latency, -// build in redundancy, and increase session token validity. For more information, -// see Managing AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) +// The AWS Security Token Service (STS) has a default endpoint of https://sts.amazonaws.com +// that maps to the US East (N. Virginia) region. Additional regions are available +// and are activated by default. For more information, see Activating and Deactivating +// AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. // -// Most AWS Regions are enabled for operations in all AWS services by default. -// Those Regions are automatically activated for use with AWS STS. Some Regions, -// such as Asia Pacific (Hong Kong), must be manually enabled. To learn more -// about enabling and disabling AWS Regions, see Managing AWS Regions (https://docs.aws.amazon.com/general/latest/gr/rande-manage.html) -// in the AWS General Reference. When you enable these AWS Regions, they are -// automatically activated for use with AWS STS. You cannot activate the STS -// endpoint for a Region that is disabled. Tokens that are valid in all AWS -// Regions are longer than tokens that are valid in Regions that are enabled -// by default. Changing this setting might affect existing systems where you -// temporarily store tokens. For more information, see Managing Global Endpoint -// Session Tokens (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html#sts-regions-manage-tokens) -// in the IAM User Guide. -// -// After you activate a Region for use with AWS STS, you can direct AWS STS -// API calls to that Region. AWS STS recommends that you provide both the Region -// and endpoint when you make calls to a Regional endpoint. You can provide -// the Region alone for manually enabled Regions, such as Asia Pacific (Hong -// Kong). In this case, the calls are directed to the STS Regional endpoint. -// However, if you provide the Region alone for Regions enabled by default, -// the calls are directed to the global endpoint of https://sts.amazonaws.com. -// -// To view the list of AWS STS endpoints and whether they are active by default, -// see Writing Code to Use AWS STS Regions (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html#id_credentials_temp_enable-regions_writing_code) -// in the IAM User Guide. +// For information about STS endpoints, see Regions and Endpoints (http://docs.aws.amazon.com/general/latest/gr/rande.html#sts_region) +// in the AWS General Reference. // // Recording API requests // @@ -62,28 +46,8 @@ // your AWS account and delivers log files to an Amazon S3 bucket. By using // information collected by CloudTrail, you can determine what requests were // successfully made to STS, who made the request, when it was made, and so -// on. -// -// If you activate AWS STS endpoints in Regions other than the default global -// endpoint, then you must also turn on CloudTrail logging in those Regions. -// This is necessary to record any AWS STS API calls that are made in those -// Regions. For more information, see Turning On CloudTrail in Additional Regions -// (https://docs.aws.amazon.com/awscloudtrail/latest/userguide/aggregating_logs_regions_turn_on_ct.html) -// in the AWS CloudTrail User Guide. -// -// AWS Security Token Service (STS) is a global service with a single endpoint -// at https://sts.amazonaws.com. Calls to this endpoint are logged as calls -// to a global service. However, because this endpoint is physically located -// in the US East (N. Virginia) Region, your logs list us-east-1 as the event -// Region. CloudTrail does not write these logs to the US East (Ohio) Region -// unless you choose to include global service logs in that Region. CloudTrail -// writes calls to all Regional endpoints to their respective Regions. For example, -// calls to sts.us-east-2.amazonaws.com are published to the US East (Ohio) -// Region and calls to sts.eu-central-1.amazonaws.com are published to the EU -// (Frankfurt) Region. -// -// To learn more about CloudTrail, including how to turn it on and find your -// log files, see the AWS CloudTrail User Guide (https://docs.aws.amazon.com/awscloudtrail/latest/userguide/what_is_cloud_trail_top_level.html). +// on. To learn more about CloudTrail, including how to turn it on and find +// your log files, see the AWS CloudTrail User Guide (http://docs.aws.amazon.com/awscloudtrail/latest/userguide/what_is_cloud_trail_top_level.html). // // See https://docs.aws.amazon.com/goto/WebAPI/sts-2011-06-15 for more information on this service. // diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go b/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go index 41ea09c35..e24884ef3 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go +++ b/vendor/github.com/aws/aws-sdk-go/service/sts/errors.go @@ -67,7 +67,7 @@ const ( // STS is not activated in the requested region for the account that is being // asked to generate credentials. The account administrator must use the IAM // console to activate STS in that region. For more information, see Activating - // and Deactivating AWS STS in an AWS Region (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) + // and Deactivating AWS STS in an AWS Region (http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_enable-regions.html) // in the IAM User Guide. ErrCodeRegionDisabledException = "RegionDisabledException" ) diff --git a/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go b/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go deleted file mode 100644 index 1eba20b00..000000000 --- a/vendor/github.com/aws/aws-sdk-go/service/sts/stsiface/interface.go +++ /dev/null @@ -1,92 +0,0 @@ -// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. - -// Package stsiface provides an interface to enable mocking the AWS Security Token Service service client -// for testing your code. -// -// It is important to note that this interface will have breaking changes -// when the service model is updated and adds new API operations, paginators, -// and waiters. -package stsiface - -import ( - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/request" - "github.com/aws/aws-sdk-go/service/sts" -) - -// STSAPI provides an interface to enable mocking the -// sts.STS service client's API operation, -// paginators, and waiters. This make unit testing your code that calls out -// to the SDK's service client's calls easier. -// -// The best way to use this interface is so the SDK's service client's calls -// can be stubbed out for unit testing your code with the SDK without needing -// to inject custom request handlers into the SDK's request pipeline. -// -// // myFunc uses an SDK service client to make a request to -// // AWS Security Token Service. -// func myFunc(svc stsiface.STSAPI) bool { -// // Make svc.AssumeRole request -// } -// -// func main() { -// sess := session.New() -// svc := sts.New(sess) -// -// myFunc(svc) -// } -// -// In your _test.go file: -// -// // Define a mock struct to be used in your unit tests of myFunc. -// type mockSTSClient struct { -// stsiface.STSAPI -// } -// func (m *mockSTSClient) AssumeRole(input *sts.AssumeRoleInput) (*sts.AssumeRoleOutput, error) { -// // mock response/functionality -// } -// -// func TestMyFunc(t *testing.T) { -// // Setup Test -// mockSvc := &mockSTSClient{} -// -// myfunc(mockSvc) -// -// // Verify myFunc's functionality -// } -// -// It is important to note that this interface will have breaking changes -// when the service model is updated and adds new API operations, paginators, -// and waiters. Its suggested to use the pattern above for testing, or using -// tooling to generate mocks to satisfy the interfaces. -type STSAPI interface { - AssumeRole(*sts.AssumeRoleInput) (*sts.AssumeRoleOutput, error) - AssumeRoleWithContext(aws.Context, *sts.AssumeRoleInput, ...request.Option) (*sts.AssumeRoleOutput, error) - AssumeRoleRequest(*sts.AssumeRoleInput) (*request.Request, *sts.AssumeRoleOutput) - - AssumeRoleWithSAML(*sts.AssumeRoleWithSAMLInput) (*sts.AssumeRoleWithSAMLOutput, error) - AssumeRoleWithSAMLWithContext(aws.Context, *sts.AssumeRoleWithSAMLInput, ...request.Option) (*sts.AssumeRoleWithSAMLOutput, error) - AssumeRoleWithSAMLRequest(*sts.AssumeRoleWithSAMLInput) (*request.Request, *sts.AssumeRoleWithSAMLOutput) - - AssumeRoleWithWebIdentity(*sts.AssumeRoleWithWebIdentityInput) (*sts.AssumeRoleWithWebIdentityOutput, error) - AssumeRoleWithWebIdentityWithContext(aws.Context, *sts.AssumeRoleWithWebIdentityInput, ...request.Option) (*sts.AssumeRoleWithWebIdentityOutput, error) - AssumeRoleWithWebIdentityRequest(*sts.AssumeRoleWithWebIdentityInput) (*request.Request, *sts.AssumeRoleWithWebIdentityOutput) - - DecodeAuthorizationMessage(*sts.DecodeAuthorizationMessageInput) (*sts.DecodeAuthorizationMessageOutput, error) - DecodeAuthorizationMessageWithContext(aws.Context, *sts.DecodeAuthorizationMessageInput, ...request.Option) (*sts.DecodeAuthorizationMessageOutput, error) - DecodeAuthorizationMessageRequest(*sts.DecodeAuthorizationMessageInput) (*request.Request, *sts.DecodeAuthorizationMessageOutput) - - GetCallerIdentity(*sts.GetCallerIdentityInput) (*sts.GetCallerIdentityOutput, error) - GetCallerIdentityWithContext(aws.Context, *sts.GetCallerIdentityInput, ...request.Option) (*sts.GetCallerIdentityOutput, error) - GetCallerIdentityRequest(*sts.GetCallerIdentityInput) (*request.Request, *sts.GetCallerIdentityOutput) - - GetFederationToken(*sts.GetFederationTokenInput) (*sts.GetFederationTokenOutput, error) - GetFederationTokenWithContext(aws.Context, *sts.GetFederationTokenInput, ...request.Option) (*sts.GetFederationTokenOutput, error) - GetFederationTokenRequest(*sts.GetFederationTokenInput) (*request.Request, *sts.GetFederationTokenOutput) - - GetSessionToken(*sts.GetSessionTokenInput) (*sts.GetSessionTokenOutput, error) - GetSessionTokenWithContext(aws.Context, *sts.GetSessionTokenInput, ...request.Option) (*sts.GetSessionTokenOutput, error) - GetSessionTokenRequest(*sts.GetSessionTokenInput) (*request.Request, *sts.GetSessionTokenOutput) -} - -var _ STSAPI = (*sts.STS)(nil) diff --git a/vendor/github.com/go-ini/ini/.gitignore b/vendor/github.com/go-ini/ini/.gitignore new file mode 100644 index 000000000..c5203bf6e --- /dev/null +++ b/vendor/github.com/go-ini/ini/.gitignore @@ -0,0 +1,5 @@ +testdata/conf_out.ini +ini.sublime-project +ini.sublime-workspace +testdata/conf_reflect.ini +.idea diff --git a/vendor/github.com/go-ini/ini/.travis.yml b/vendor/github.com/go-ini/ini/.travis.yml new file mode 100644 index 000000000..65c872bad --- /dev/null +++ b/vendor/github.com/go-ini/ini/.travis.yml @@ -0,0 +1,17 @@ +sudo: false +language: go +go: + - 1.4.x + - 1.5.x + - 1.6.x + - 1.7.x + - master + +script: + - go get golang.org/x/tools/cmd/cover + - go get github.com/smartystreets/goconvey + - go test -v -cover -race + +notifications: + email: + - u@gogs.io diff --git a/vendor/github.com/go-ini/ini/LICENSE b/vendor/github.com/go-ini/ini/LICENSE new file mode 100644 index 000000000..37ec93a14 --- /dev/null +++ b/vendor/github.com/go-ini/ini/LICENSE @@ -0,0 +1,191 @@ +Apache License +Version 2.0, January 2004 +http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + +"License" shall mean the terms and conditions for use, reproduction, and +distribution as defined by Sections 1 through 9 of this document. + +"Licensor" shall mean the copyright owner or entity authorized by the copyright +owner that is granting the License. + +"Legal Entity" shall mean the union of the acting entity and all other entities +that control, are controlled by, or are under common control with that entity. +For the purposes of this definition, "control" means (i) the power, direct or +indirect, to cause the direction or management of such entity, whether by +contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the +outstanding shares, or (iii) beneficial ownership of such entity. + +"You" (or "Your") shall mean an individual or Legal Entity exercising +permissions granted by this License. + +"Source" form shall mean the preferred form for making modifications, including +but not limited to software source code, documentation source, and configuration +files. + +"Object" form shall mean any form resulting from mechanical transformation or +translation of a Source form, including but not limited to compiled object code, +generated documentation, and conversions to other media types. + +"Work" shall mean the work of authorship, whether in Source or Object form, made +available under the License, as indicated by a copyright notice that is included +in or attached to the work (an example is provided in the Appendix below). + +"Derivative Works" shall mean any work, whether in Source or Object form, that +is based on (or derived from) the Work and for which the editorial revisions, +annotations, elaborations, or other modifications represent, as a whole, an +original work of authorship. For the purposes of this License, Derivative Works +shall not include works that remain separable from, or merely link (or bind by +name) to the interfaces of, the Work and Derivative Works thereof. + +"Contribution" shall mean any work of authorship, including the original version +of the Work and any modifications or additions to that Work or Derivative Works +thereof, that is intentionally submitted to Licensor for inclusion in the Work +by the copyright owner or by an individual or Legal Entity authorized to submit +on behalf of the copyright owner. For the purposes of this definition, +"submitted" means any form of electronic, verbal, or written communication sent +to the Licensor or its representatives, including but not limited to +communication on electronic mailing lists, source code control systems, and +issue tracking systems that are managed by, or on behalf of, the Licensor for +the purpose of discussing and improving the Work, but excluding communication +that is conspicuously marked or otherwise designated in writing by the copyright +owner as "Not a Contribution." + +"Contributor" shall mean Licensor and any individual or Legal Entity on behalf +of whom a Contribution has been received by Licensor and subsequently +incorporated within the Work. + +2. Grant of Copyright License. + +Subject to the terms and conditions of this License, each Contributor hereby +grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, +irrevocable copyright license to reproduce, prepare Derivative Works of, +publicly display, publicly perform, sublicense, and distribute the Work and such +Derivative Works in Source or Object form. + +3. Grant of Patent License. + +Subject to the terms and conditions of this License, each Contributor hereby +grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, +irrevocable (except as stated in this section) patent license to make, have +made, use, offer to sell, sell, import, and otherwise transfer the Work, where +such license applies only to those patent claims licensable by such Contributor +that are necessarily infringed by their Contribution(s) alone or by combination +of their Contribution(s) with the Work to which such Contribution(s) was +submitted. If You institute patent litigation against any entity (including a +cross-claim or counterclaim in a lawsuit) alleging that the Work or a +Contribution incorporated within the Work constitutes direct or contributory +patent infringement, then any patent licenses granted to You under this License +for that Work shall terminate as of the date such litigation is filed. + +4. Redistribution. + +You may reproduce and distribute copies of the Work or Derivative Works thereof +in any medium, with or without modifications, and in Source or Object form, +provided that You meet the following conditions: + +You must give any other recipients of the Work or Derivative Works a copy of +this License; and +You must cause any modified files to carry prominent notices stating that You +changed the files; and +You must retain, in the Source form of any Derivative Works that You distribute, +all copyright, patent, trademark, and attribution notices from the Source form +of the Work, excluding those notices that do not pertain to any part of the +Derivative Works; and +If the Work includes a "NOTICE" text file as part of its distribution, then any +Derivative Works that You distribute must include a readable copy of the +attribution notices contained within such NOTICE file, excluding those notices +that do not pertain to any part of the Derivative Works, in at least one of the +following places: within a NOTICE text file distributed as part of the +Derivative Works; within the Source form or documentation, if provided along +with the Derivative Works; or, within a display generated by the Derivative +Works, if and wherever such third-party notices normally appear. The contents of +the NOTICE file are for informational purposes only and do not modify the +License. You may add Your own attribution notices within Derivative Works that +You distribute, alongside or as an addendum to the NOTICE text from the Work, +provided that such additional attribution notices cannot be construed as +modifying the License. +You may add Your own copyright statement to Your modifications and may provide +additional or different license terms and conditions for use, reproduction, or +distribution of Your modifications, or for any such Derivative Works as a whole, +provided Your use, reproduction, and distribution of the Work otherwise complies +with the conditions stated in this License. + +5. Submission of Contributions. + +Unless You explicitly state otherwise, any Contribution intentionally submitted +for inclusion in the Work by You to the Licensor shall be under the terms and +conditions of this License, without any additional terms or conditions. +Notwithstanding the above, nothing herein shall supersede or modify the terms of +any separate license agreement you may have executed with Licensor regarding +such Contributions. + +6. Trademarks. + +This License does not grant permission to use the trade names, trademarks, +service marks, or product names of the Licensor, except as required for +reasonable and customary use in describing the origin of the Work and +reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. + +Unless required by applicable law or agreed to in writing, Licensor provides the +Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, +including, without limitation, any warranties or conditions of TITLE, +NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are +solely responsible for determining the appropriateness of using or +redistributing the Work and assume any risks associated with Your exercise of +permissions under this License. + +8. Limitation of Liability. + +In no event and under no legal theory, whether in tort (including negligence), +contract, or otherwise, unless required by applicable law (such as deliberate +and grossly negligent acts) or agreed to in writing, shall any Contributor be +liable to You for damages, including any direct, indirect, special, incidental, +or consequential damages of any character arising as a result of this License or +out of the use or inability to use the Work (including but not limited to +damages for loss of goodwill, work stoppage, computer failure or malfunction, or +any and all other commercial damages or losses), even if such Contributor has +been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. + +While redistributing the Work or Derivative Works thereof, You may choose to +offer, and charge a fee for, acceptance of support, warranty, indemnity, or +other liability obligations and/or rights consistent with this License. However, +in accepting such obligations, You may act only on Your own behalf and on Your +sole responsibility, not on behalf of any other Contributor, and only if You +agree to indemnify, defend, and hold each Contributor harmless for any liability +incurred by, or claims asserted against, such Contributor by reason of your +accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS + +APPENDIX: How to apply the Apache License to your work + +To apply the Apache License to your work, attach the following boilerplate +notice, with the fields enclosed by brackets "[]" replaced with your own +identifying information. (Don't include the brackets!) The text should be +enclosed in the appropriate comment syntax for the file format. We also +recommend that a file or class name and description of purpose be included on +the same "printed page" as the copyright notice for easier identification within +third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/vendor/github.com/go-ini/ini/Makefile b/vendor/github.com/go-ini/ini/Makefile new file mode 100644 index 000000000..ac034e525 --- /dev/null +++ b/vendor/github.com/go-ini/ini/Makefile @@ -0,0 +1,12 @@ +.PHONY: build test bench vet + +build: vet bench + +test: + go test -v -cover -race + +bench: + go test -v -cover -race -test.bench=. -test.benchmem + +vet: + go vet diff --git a/vendor/github.com/go-ini/ini/README.md b/vendor/github.com/go-ini/ini/README.md new file mode 100644 index 000000000..85947422d --- /dev/null +++ b/vendor/github.com/go-ini/ini/README.md @@ -0,0 +1,740 @@ +INI [![Build Status](https://travis-ci.org/go-ini/ini.svg?branch=master)](https://travis-ci.org/go-ini/ini) [![Sourcegraph](https://sourcegraph.com/github.com/go-ini/ini/-/badge.svg)](https://sourcegraph.com/github.com/go-ini/ini?badge) +=== + +![](https://avatars0.githubusercontent.com/u/10216035?v=3&s=200) + +Package ini provides INI file read and write functionality in Go. + +[简体中文](README_ZH.md) + +## Feature + +- Load multiple data sources(`[]byte`, file and `io.ReadCloser`) with overwrites. +- Read with recursion values. +- Read with parent-child sections. +- Read with auto-increment key names. +- Read with multiple-line values. +- Read with tons of helper methods. +- Read and convert values to Go types. +- Read and **WRITE** comments of sections and keys. +- Manipulate sections, keys and comments with ease. +- Keep sections and keys in order as you parse and save. + +## Installation + +To use a tagged revision: + + go get gopkg.in/ini.v1 + +To use with latest changes: + + go get github.com/go-ini/ini + +Please add `-u` flag to update in the future. + +### Testing + +If you want to test on your machine, please apply `-t` flag: + + go get -t gopkg.in/ini.v1 + +Please add `-u` flag to update in the future. + +## Getting Started + +### Loading from data sources + +A **Data Source** is either raw data in type `[]byte`, a file name with type `string` or `io.ReadCloser`. You can load **as many data sources as you want**. Passing other types will simply return an error. + +```go +cfg, err := ini.Load([]byte("raw data"), "filename", ioutil.NopCloser(bytes.NewReader([]byte("some other data")))) +``` + +Or start with an empty object: + +```go +cfg := ini.Empty() +``` + +When you cannot decide how many data sources to load at the beginning, you will still be able to **Append()** them later. + +```go +err := cfg.Append("other file", []byte("other raw data")) +``` + +If you have a list of files with possibilities that some of them may not available at the time, and you don't know exactly which ones, you can use `LooseLoad` to ignore nonexistent files without returning error. + +```go +cfg, err := ini.LooseLoad("filename", "filename_404") +``` + +The cool thing is, whenever the file is available to load while you're calling `Reload` method, it will be counted as usual. + +#### Ignore cases of key name + +When you do not care about cases of section and key names, you can use `InsensitiveLoad` to force all names to be lowercased while parsing. + +```go +cfg, err := ini.InsensitiveLoad("filename") +//... + +// sec1 and sec2 are the exactly same section object +sec1, err := cfg.GetSection("Section") +sec2, err := cfg.GetSection("SecTIOn") + +// key1 and key2 are the exactly same key object +key1, err := cfg.GetKey("Key") +key2, err := cfg.GetKey("KeY") +``` + +#### MySQL-like boolean key + +MySQL's configuration allows a key without value as follows: + +```ini +[mysqld] +... +skip-host-cache +skip-name-resolve +``` + +By default, this is considered as missing value. But if you know you're going to deal with those cases, you can assign advanced load options: + +```go +cfg, err := LoadSources(LoadOptions{AllowBooleanKeys: true}, "my.cnf")) +``` + +The value of those keys are always `true`, and when you save to a file, it will keep in the same foramt as you read. + +To generate such keys in your program, you could use `NewBooleanKey`: + +```go +key, err := sec.NewBooleanKey("skip-host-cache") +``` + +#### Comment + +Take care that following format will be treated as comment: + +1. Line begins with `#` or `;` +2. Words after `#` or `;` +3. Words after section name (i.e words after `[some section name]`) + +If you want to save a value with `#` or `;`, please quote them with ``` ` ``` or ``` """ ```. + +### Working with sections + +To get a section, you would need to: + +```go +section, err := cfg.GetSection("section name") +``` + +For a shortcut for default section, just give an empty string as name: + +```go +section, err := cfg.GetSection("") +``` + +When you're pretty sure the section exists, following code could make your life easier: + +```go +section := cfg.Section("section name") +``` + +What happens when the section somehow does not exist? Don't panic, it automatically creates and returns a new section to you. + +To create a new section: + +```go +err := cfg.NewSection("new section") +``` + +To get a list of sections or section names: + +```go +sections := cfg.Sections() +names := cfg.SectionStrings() +``` + +### Working with keys + +To get a key under a section: + +```go +key, err := cfg.Section("").GetKey("key name") +``` + +Same rule applies to key operations: + +```go +key := cfg.Section("").Key("key name") +``` + +To check if a key exists: + +```go +yes := cfg.Section("").HasKey("key name") +``` + +To create a new key: + +```go +err := cfg.Section("").NewKey("name", "value") +``` + +To get a list of keys or key names: + +```go +keys := cfg.Section("").Keys() +names := cfg.Section("").KeyStrings() +``` + +To get a clone hash of keys and corresponding values: + +```go +hash := cfg.Section("").KeysHash() +``` + +### Working with values + +To get a string value: + +```go +val := cfg.Section("").Key("key name").String() +``` + +To validate key value on the fly: + +```go +val := cfg.Section("").Key("key name").Validate(func(in string) string { + if len(in) == 0 { + return "default" + } + return in +}) +``` + +If you do not want any auto-transformation (such as recursive read) for the values, you can get raw value directly (this way you get much better performance): + +```go +val := cfg.Section("").Key("key name").Value() +``` + +To check if raw value exists: + +```go +yes := cfg.Section("").HasValue("test value") +``` + +To get value with types: + +```go +// For boolean values: +// true when value is: 1, t, T, TRUE, true, True, YES, yes, Yes, y, ON, on, On +// false when value is: 0, f, F, FALSE, false, False, NO, no, No, n, OFF, off, Off +v, err = cfg.Section("").Key("BOOL").Bool() +v, err = cfg.Section("").Key("FLOAT64").Float64() +v, err = cfg.Section("").Key("INT").Int() +v, err = cfg.Section("").Key("INT64").Int64() +v, err = cfg.Section("").Key("UINT").Uint() +v, err = cfg.Section("").Key("UINT64").Uint64() +v, err = cfg.Section("").Key("TIME").TimeFormat(time.RFC3339) +v, err = cfg.Section("").Key("TIME").Time() // RFC3339 + +v = cfg.Section("").Key("BOOL").MustBool() +v = cfg.Section("").Key("FLOAT64").MustFloat64() +v = cfg.Section("").Key("INT").MustInt() +v = cfg.Section("").Key("INT64").MustInt64() +v = cfg.Section("").Key("UINT").MustUint() +v = cfg.Section("").Key("UINT64").MustUint64() +v = cfg.Section("").Key("TIME").MustTimeFormat(time.RFC3339) +v = cfg.Section("").Key("TIME").MustTime() // RFC3339 + +// Methods start with Must also accept one argument for default value +// when key not found or fail to parse value to given type. +// Except method MustString, which you have to pass a default value. + +v = cfg.Section("").Key("String").MustString("default") +v = cfg.Section("").Key("BOOL").MustBool(true) +v = cfg.Section("").Key("FLOAT64").MustFloat64(1.25) +v = cfg.Section("").Key("INT").MustInt(10) +v = cfg.Section("").Key("INT64").MustInt64(99) +v = cfg.Section("").Key("UINT").MustUint(3) +v = cfg.Section("").Key("UINT64").MustUint64(6) +v = cfg.Section("").Key("TIME").MustTimeFormat(time.RFC3339, time.Now()) +v = cfg.Section("").Key("TIME").MustTime(time.Now()) // RFC3339 +``` + +What if my value is three-line long? + +```ini +[advance] +ADDRESS = """404 road, +NotFound, State, 5000 +Earth""" +``` + +Not a problem! + +```go +cfg.Section("advance").Key("ADDRESS").String() + +/* --- start --- +404 road, +NotFound, State, 5000 +Earth +------ end --- */ +``` + +That's cool, how about continuation lines? + +```ini +[advance] +two_lines = how about \ + continuation lines? +lots_of_lines = 1 \ + 2 \ + 3 \ + 4 +``` + +Piece of cake! + +```go +cfg.Section("advance").Key("two_lines").String() // how about continuation lines? +cfg.Section("advance").Key("lots_of_lines").String() // 1 2 3 4 +``` + +Well, I hate continuation lines, how do I disable that? + +```go +cfg, err := ini.LoadSources(ini.LoadOptions{ + IgnoreContinuation: true, +}, "filename") +``` + +Holy crap! + +Note that single quotes around values will be stripped: + +```ini +foo = "some value" // foo: some value +bar = 'some value' // bar: some value +``` + +That's all? Hmm, no. + +#### Helper methods of working with values + +To get value with given candidates: + +```go +v = cfg.Section("").Key("STRING").In("default", []string{"str", "arr", "types"}) +v = cfg.Section("").Key("FLOAT64").InFloat64(1.1, []float64{1.25, 2.5, 3.75}) +v = cfg.Section("").Key("INT").InInt(5, []int{10, 20, 30}) +v = cfg.Section("").Key("INT64").InInt64(10, []int64{10, 20, 30}) +v = cfg.Section("").Key("UINT").InUint(4, []int{3, 6, 9}) +v = cfg.Section("").Key("UINT64").InUint64(8, []int64{3, 6, 9}) +v = cfg.Section("").Key("TIME").InTimeFormat(time.RFC3339, time.Now(), []time.Time{time1, time2, time3}) +v = cfg.Section("").Key("TIME").InTime(time.Now(), []time.Time{time1, time2, time3}) // RFC3339 +``` + +Default value will be presented if value of key is not in candidates you given, and default value does not need be one of candidates. + +To validate value in a given range: + +```go +vals = cfg.Section("").Key("FLOAT64").RangeFloat64(0.0, 1.1, 2.2) +vals = cfg.Section("").Key("INT").RangeInt(0, 10, 20) +vals = cfg.Section("").Key("INT64").RangeInt64(0, 10, 20) +vals = cfg.Section("").Key("UINT").RangeUint(0, 3, 9) +vals = cfg.Section("").Key("UINT64").RangeUint64(0, 3, 9) +vals = cfg.Section("").Key("TIME").RangeTimeFormat(time.RFC3339, time.Now(), minTime, maxTime) +vals = cfg.Section("").Key("TIME").RangeTime(time.Now(), minTime, maxTime) // RFC3339 +``` + +##### Auto-split values into a slice + +To use zero value of type for invalid inputs: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> [0.0 2.2 0.0 0.0] +vals = cfg.Section("").Key("STRINGS").Strings(",") +vals = cfg.Section("").Key("FLOAT64S").Float64s(",") +vals = cfg.Section("").Key("INTS").Ints(",") +vals = cfg.Section("").Key("INT64S").Int64s(",") +vals = cfg.Section("").Key("UINTS").Uints(",") +vals = cfg.Section("").Key("UINT64S").Uint64s(",") +vals = cfg.Section("").Key("TIMES").Times(",") +``` + +To exclude invalid values out of result slice: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> [2.2] +vals = cfg.Section("").Key("FLOAT64S").ValidFloat64s(",") +vals = cfg.Section("").Key("INTS").ValidInts(",") +vals = cfg.Section("").Key("INT64S").ValidInt64s(",") +vals = cfg.Section("").Key("UINTS").ValidUints(",") +vals = cfg.Section("").Key("UINT64S").ValidUint64s(",") +vals = cfg.Section("").Key("TIMES").ValidTimes(",") +``` + +Or to return nothing but error when have invalid inputs: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> error +vals = cfg.Section("").Key("FLOAT64S").StrictFloat64s(",") +vals = cfg.Section("").Key("INTS").StrictInts(",") +vals = cfg.Section("").Key("INT64S").StrictInt64s(",") +vals = cfg.Section("").Key("UINTS").StrictUints(",") +vals = cfg.Section("").Key("UINT64S").StrictUint64s(",") +vals = cfg.Section("").Key("TIMES").StrictTimes(",") +``` + +### Save your configuration + +Finally, it's time to save your configuration to somewhere. + +A typical way to save configuration is writing it to a file: + +```go +// ... +err = cfg.SaveTo("my.ini") +err = cfg.SaveToIndent("my.ini", "\t") +``` + +Another way to save is writing to a `io.Writer` interface: + +```go +// ... +cfg.WriteTo(writer) +cfg.WriteToIndent(writer, "\t") +``` + +By default, spaces are used to align "=" sign between key and values, to disable that: + +```go +ini.PrettyFormat = false +``` + +## Advanced Usage + +### Recursive Values + +For all value of keys, there is a special syntax `%()s`, where `` is the key name in same section or default section, and `%()s` will be replaced by corresponding value(empty string if key not found). You can use this syntax at most 99 level of recursions. + +```ini +NAME = ini + +[author] +NAME = Unknwon +GITHUB = https://github.com/%(NAME)s + +[package] +FULL_NAME = github.com/go-ini/%(NAME)s +``` + +```go +cfg.Section("author").Key("GITHUB").String() // https://github.com/Unknwon +cfg.Section("package").Key("FULL_NAME").String() // github.com/go-ini/ini +``` + +### Parent-child Sections + +You can use `.` in section name to indicate parent-child relationship between two or more sections. If the key not found in the child section, library will try again on its parent section until there is no parent section. + +```ini +NAME = ini +VERSION = v1 +IMPORT_PATH = gopkg.in/%(NAME)s.%(VERSION)s + +[package] +CLONE_URL = https://%(IMPORT_PATH)s + +[package.sub] +``` + +```go +cfg.Section("package.sub").Key("CLONE_URL").String() // https://gopkg.in/ini.v1 +``` + +#### Retrieve parent keys available to a child section + +```go +cfg.Section("package.sub").ParentKeys() // ["CLONE_URL"] +``` + +### Unparseable Sections + +Sometimes, you have sections that do not contain key-value pairs but raw content, to handle such case, you can use `LoadOptions.UnparsableSections`: + +```go +cfg, err := LoadSources(LoadOptions{UnparseableSections: []string{"COMMENTS"}}, `[COMMENTS] +<1> This slide has the fuel listed in the wrong units `)) + +body := cfg.Section("COMMENTS").Body() + +/* --- start --- +<1> This slide has the fuel listed in the wrong units +------ end --- */ +``` + +### Auto-increment Key Names + +If key name is `-` in data source, then it would be seen as special syntax for auto-increment key name start from 1, and every section is independent on counter. + +```ini +[features] +-: Support read/write comments of keys and sections +-: Support auto-increment of key names +-: Support load multiple files to overwrite key values +``` + +```go +cfg.Section("features").KeyStrings() // []{"#1", "#2", "#3"} +``` + +### Map To Struct + +Want more objective way to play with INI? Cool. + +```ini +Name = Unknwon +age = 21 +Male = true +Born = 1993-01-01T20:17:05Z + +[Note] +Content = Hi is a good man! +Cities = HangZhou, Boston +``` + +```go +type Note struct { + Content string + Cities []string +} + +type Person struct { + Name string + Age int `ini:"age"` + Male bool + Born time.Time + Note + Created time.Time `ini:"-"` +} + +func main() { + cfg, err := ini.Load("path/to/ini") + // ... + p := new(Person) + err = cfg.MapTo(p) + // ... + + // Things can be simpler. + err = ini.MapTo(p, "path/to/ini") + // ... + + // Just map a section? Fine. + n := new(Note) + err = cfg.Section("Note").MapTo(n) + // ... +} +``` + +Can I have default value for field? Absolutely. + +Assign it before you map to struct. It will keep the value as it is if the key is not presented or got wrong type. + +```go +// ... +p := &Person{ + Name: "Joe", +} +// ... +``` + +It's really cool, but what's the point if you can't give me my file back from struct? + +### Reflect From Struct + +Why not? + +```go +type Embeded struct { + Dates []time.Time `delim:"|"` + Places []string `ini:"places,omitempty"` + None []int `ini:",omitempty"` +} + +type Author struct { + Name string `ini:"NAME"` + Male bool + Age int + GPA float64 + NeverMind string `ini:"-"` + *Embeded +} + +func main() { + a := &Author{"Unknwon", true, 21, 2.8, "", + &Embeded{ + []time.Time{time.Now(), time.Now()}, + []string{"HangZhou", "Boston"}, + []int{}, + }} + cfg := ini.Empty() + err = ini.ReflectFrom(cfg, a) + // ... +} +``` + +So, what do I get? + +```ini +NAME = Unknwon +Male = true +Age = 21 +GPA = 2.8 + +[Embeded] +Dates = 2015-08-07T22:14:22+08:00|2015-08-07T22:14:22+08:00 +places = HangZhou,Boston +``` + +#### Name Mapper + +To save your time and make your code cleaner, this library supports [`NameMapper`](https://gowalker.org/gopkg.in/ini.v1#NameMapper) between struct field and actual section and key name. + +There are 2 built-in name mappers: + +- `AllCapsUnderscore`: it converts to format `ALL_CAPS_UNDERSCORE` then match section or key. +- `TitleUnderscore`: it converts to format `title_underscore` then match section or key. + +To use them: + +```go +type Info struct { + PackageName string +} + +func main() { + err = ini.MapToWithMapper(&Info{}, ini.TitleUnderscore, []byte("package_name=ini")) + // ... + + cfg, err := ini.Load([]byte("PACKAGE_NAME=ini")) + // ... + info := new(Info) + cfg.NameMapper = ini.AllCapsUnderscore + err = cfg.MapTo(info) + // ... +} +``` + +Same rules of name mapper apply to `ini.ReflectFromWithMapper` function. + +#### Value Mapper + +To expand values (e.g. from environment variables), you can use the `ValueMapper` to transform values: + +```go +type Env struct { + Foo string `ini:"foo"` +} + +func main() { + cfg, err := ini.Load([]byte("[env]\nfoo = ${MY_VAR}\n") + cfg.ValueMapper = os.ExpandEnv + // ... + env := &Env{} + err = cfg.Section("env").MapTo(env) +} +``` + +This would set the value of `env.Foo` to the value of the environment variable `MY_VAR`. + +#### Other Notes On Map/Reflect + +Any embedded struct is treated as a section by default, and there is no automatic parent-child relations in map/reflect feature: + +```go +type Child struct { + Age string +} + +type Parent struct { + Name string + Child +} + +type Config struct { + City string + Parent +} +``` + +Example configuration: + +```ini +City = Boston + +[Parent] +Name = Unknwon + +[Child] +Age = 21 +``` + +What if, yes, I'm paranoid, I want embedded struct to be in the same section. Well, all roads lead to Rome. + +```go +type Child struct { + Age string +} + +type Parent struct { + Name string + Child `ini:"Parent"` +} + +type Config struct { + City string + Parent +} +``` + +Example configuration: + +```ini +City = Boston + +[Parent] +Name = Unknwon +Age = 21 +``` + +## Getting Help + +- [API Documentation](https://gowalker.org/gopkg.in/ini.v1) +- [File An Issue](https://github.com/go-ini/ini/issues/new) + +## FAQs + +### What does `BlockMode` field do? + +By default, library lets you read and write values so we need a locker to make sure your data is safe. But in cases that you are very sure about only reading data through the library, you can set `cfg.BlockMode = false` to speed up read operations about **50-70%** faster. + +### Why another INI library? + +Many people are using my another INI library [goconfig](https://github.com/Unknwon/goconfig), so the reason for this one is I would like to make more Go style code. Also when you set `cfg.BlockMode = false`, this one is about **10-30%** faster. + +To make those changes I have to confirm API broken, so it's safer to keep it in another place and start using `gopkg.in` to version my package at this time.(PS: shorter import path) + +## License + +This project is under Apache v2 License. See the [LICENSE](LICENSE) file for the full license text. diff --git a/vendor/github.com/go-ini/ini/README_ZH.md b/vendor/github.com/go-ini/ini/README_ZH.md new file mode 100644 index 000000000..163432db9 --- /dev/null +++ b/vendor/github.com/go-ini/ini/README_ZH.md @@ -0,0 +1,727 @@ +本包提供了 Go 语言中读写 INI 文件的功能。 + +## 功能特性 + +- 支持覆盖加载多个数据源(`[]byte`、文件和 `io.ReadCloser`) +- 支持递归读取键值 +- 支持读取父子分区 +- 支持读取自增键名 +- 支持读取多行的键值 +- 支持大量辅助方法 +- 支持在读取时直接转换为 Go 语言类型 +- 支持读取和 **写入** 分区和键的注释 +- 轻松操作分区、键值和注释 +- 在保存文件时分区和键值会保持原有的顺序 + +## 下载安装 + +使用一个特定版本: + + go get gopkg.in/ini.v1 + +使用最新版: + + go get github.com/go-ini/ini + +如需更新请添加 `-u` 选项。 + +### 测试安装 + +如果您想要在自己的机器上运行测试,请使用 `-t` 标记: + + go get -t gopkg.in/ini.v1 + +如需更新请添加 `-u` 选项。 + +## 开始使用 + +### 从数据源加载 + +一个 **数据源** 可以是 `[]byte` 类型的原始数据,`string` 类型的文件路径或 `io.ReadCloser`。您可以加载 **任意多个** 数据源。如果您传递其它类型的数据源,则会直接返回错误。 + +```go +cfg, err := ini.Load([]byte("raw data"), "filename", ioutil.NopCloser(bytes.NewReader([]byte("some other data")))) +``` + +或者从一个空白的文件开始: + +```go +cfg := ini.Empty() +``` + +当您在一开始无法决定需要加载哪些数据源时,仍可以使用 **Append()** 在需要的时候加载它们。 + +```go +err := cfg.Append("other file", []byte("other raw data")) +``` + +当您想要加载一系列文件,但是不能够确定其中哪些文件是不存在的,可以通过调用函数 `LooseLoad` 来忽略它们(`Load` 会因为文件不存在而返回错误): + +```go +cfg, err := ini.LooseLoad("filename", "filename_404") +``` + +更牛逼的是,当那些之前不存在的文件在重新调用 `Reload` 方法的时候突然出现了,那么它们会被正常加载。 + +#### 忽略键名的大小写 + +有时候分区和键的名称大小写混合非常烦人,这个时候就可以通过 `InsensitiveLoad` 将所有分区和键名在读取里强制转换为小写: + +```go +cfg, err := ini.InsensitiveLoad("filename") +//... + +// sec1 和 sec2 指向同一个分区对象 +sec1, err := cfg.GetSection("Section") +sec2, err := cfg.GetSection("SecTIOn") + +// key1 和 key2 指向同一个键对象 +key1, err := cfg.GetKey("Key") +key2, err := cfg.GetKey("KeY") +``` + +#### 类似 MySQL 配置中的布尔值键 + +MySQL 的配置文件中会出现没有具体值的布尔类型的键: + +```ini +[mysqld] +... +skip-host-cache +skip-name-resolve +``` + +默认情况下这被认为是缺失值而无法完成解析,但可以通过高级的加载选项对它们进行处理: + +```go +cfg, err := LoadSources(LoadOptions{AllowBooleanKeys: true}, "my.cnf")) +``` + +这些键的值永远为 `true`,且在保存到文件时也只会输出键名。 + +如果您想要通过程序来生成此类键,则可以使用 `NewBooleanKey`: + +```go +key, err := sec.NewBooleanKey("skip-host-cache") +``` + +#### 关于注释 + +下述几种情况的内容将被视为注释: + +1. 所有以 `#` 或 `;` 开头的行 +2. 所有在 `#` 或 `;` 之后的内容 +3. 分区标签后的文字 (即 `[分区名]` 之后的内容) + +如果你希望使用包含 `#` 或 `;` 的值,请使用 ``` ` ``` 或 ``` """ ``` 进行包覆。 + +### 操作分区(Section) + +获取指定分区: + +```go +section, err := cfg.GetSection("section name") +``` + +如果您想要获取默认分区,则可以用空字符串代替分区名: + +```go +section, err := cfg.GetSection("") +``` + +当您非常确定某个分区是存在的,可以使用以下简便方法: + +```go +section := cfg.Section("section name") +``` + +如果不小心判断错了,要获取的分区其实是不存在的,那会发生什么呢?没事的,它会自动创建并返回一个对应的分区对象给您。 + +创建一个分区: + +```go +err := cfg.NewSection("new section") +``` + +获取所有分区对象或名称: + +```go +sections := cfg.Sections() +names := cfg.SectionStrings() +``` + +### 操作键(Key) + +获取某个分区下的键: + +```go +key, err := cfg.Section("").GetKey("key name") +``` + +和分区一样,您也可以直接获取键而忽略错误处理: + +```go +key := cfg.Section("").Key("key name") +``` + +判断某个键是否存在: + +```go +yes := cfg.Section("").HasKey("key name") +``` + +创建一个新的键: + +```go +err := cfg.Section("").NewKey("name", "value") +``` + +获取分区下的所有键或键名: + +```go +keys := cfg.Section("").Keys() +names := cfg.Section("").KeyStrings() +``` + +获取分区下的所有键值对的克隆: + +```go +hash := cfg.Section("").KeysHash() +``` + +### 操作键值(Value) + +获取一个类型为字符串(string)的值: + +```go +val := cfg.Section("").Key("key name").String() +``` + +获取值的同时通过自定义函数进行处理验证: + +```go +val := cfg.Section("").Key("key name").Validate(func(in string) string { + if len(in) == 0 { + return "default" + } + return in +}) +``` + +如果您不需要任何对值的自动转变功能(例如递归读取),可以直接获取原值(这种方式性能最佳): + +```go +val := cfg.Section("").Key("key name").Value() +``` + +判断某个原值是否存在: + +```go +yes := cfg.Section("").HasValue("test value") +``` + +获取其它类型的值: + +```go +// 布尔值的规则: +// true 当值为:1, t, T, TRUE, true, True, YES, yes, Yes, y, ON, on, On +// false 当值为:0, f, F, FALSE, false, False, NO, no, No, n, OFF, off, Off +v, err = cfg.Section("").Key("BOOL").Bool() +v, err = cfg.Section("").Key("FLOAT64").Float64() +v, err = cfg.Section("").Key("INT").Int() +v, err = cfg.Section("").Key("INT64").Int64() +v, err = cfg.Section("").Key("UINT").Uint() +v, err = cfg.Section("").Key("UINT64").Uint64() +v, err = cfg.Section("").Key("TIME").TimeFormat(time.RFC3339) +v, err = cfg.Section("").Key("TIME").Time() // RFC3339 + +v = cfg.Section("").Key("BOOL").MustBool() +v = cfg.Section("").Key("FLOAT64").MustFloat64() +v = cfg.Section("").Key("INT").MustInt() +v = cfg.Section("").Key("INT64").MustInt64() +v = cfg.Section("").Key("UINT").MustUint() +v = cfg.Section("").Key("UINT64").MustUint64() +v = cfg.Section("").Key("TIME").MustTimeFormat(time.RFC3339) +v = cfg.Section("").Key("TIME").MustTime() // RFC3339 + +// 由 Must 开头的方法名允许接收一个相同类型的参数来作为默认值, +// 当键不存在或者转换失败时,则会直接返回该默认值。 +// 但是,MustString 方法必须传递一个默认值。 + +v = cfg.Seciont("").Key("String").MustString("default") +v = cfg.Section("").Key("BOOL").MustBool(true) +v = cfg.Section("").Key("FLOAT64").MustFloat64(1.25) +v = cfg.Section("").Key("INT").MustInt(10) +v = cfg.Section("").Key("INT64").MustInt64(99) +v = cfg.Section("").Key("UINT").MustUint(3) +v = cfg.Section("").Key("UINT64").MustUint64(6) +v = cfg.Section("").Key("TIME").MustTimeFormat(time.RFC3339, time.Now()) +v = cfg.Section("").Key("TIME").MustTime(time.Now()) // RFC3339 +``` + +如果我的值有好多行怎么办? + +```ini +[advance] +ADDRESS = """404 road, +NotFound, State, 5000 +Earth""" +``` + +嗯哼?小 case! + +```go +cfg.Section("advance").Key("ADDRESS").String() + +/* --- start --- +404 road, +NotFound, State, 5000 +Earth +------ end --- */ +``` + +赞爆了!那要是我属于一行的内容写不下想要写到第二行怎么办? + +```ini +[advance] +two_lines = how about \ + continuation lines? +lots_of_lines = 1 \ + 2 \ + 3 \ + 4 +``` + +简直是小菜一碟! + +```go +cfg.Section("advance").Key("two_lines").String() // how about continuation lines? +cfg.Section("advance").Key("lots_of_lines").String() // 1 2 3 4 +``` + +可是我有时候觉得两行连在一起特别没劲,怎么才能不自动连接两行呢? + +```go +cfg, err := ini.LoadSources(ini.LoadOptions{ + IgnoreContinuation: true, +}, "filename") +``` + +哇靠给力啊! + +需要注意的是,值两侧的单引号会被自动剔除: + +```ini +foo = "some value" // foo: some value +bar = 'some value' // bar: some value +``` + +这就是全部了?哈哈,当然不是。 + +#### 操作键值的辅助方法 + +获取键值时设定候选值: + +```go +v = cfg.Section("").Key("STRING").In("default", []string{"str", "arr", "types"}) +v = cfg.Section("").Key("FLOAT64").InFloat64(1.1, []float64{1.25, 2.5, 3.75}) +v = cfg.Section("").Key("INT").InInt(5, []int{10, 20, 30}) +v = cfg.Section("").Key("INT64").InInt64(10, []int64{10, 20, 30}) +v = cfg.Section("").Key("UINT").InUint(4, []int{3, 6, 9}) +v = cfg.Section("").Key("UINT64").InUint64(8, []int64{3, 6, 9}) +v = cfg.Section("").Key("TIME").InTimeFormat(time.RFC3339, time.Now(), []time.Time{time1, time2, time3}) +v = cfg.Section("").Key("TIME").InTime(time.Now(), []time.Time{time1, time2, time3}) // RFC3339 +``` + +如果获取到的值不是候选值的任意一个,则会返回默认值,而默认值不需要是候选值中的一员。 + +验证获取的值是否在指定范围内: + +```go +vals = cfg.Section("").Key("FLOAT64").RangeFloat64(0.0, 1.1, 2.2) +vals = cfg.Section("").Key("INT").RangeInt(0, 10, 20) +vals = cfg.Section("").Key("INT64").RangeInt64(0, 10, 20) +vals = cfg.Section("").Key("UINT").RangeUint(0, 3, 9) +vals = cfg.Section("").Key("UINT64").RangeUint64(0, 3, 9) +vals = cfg.Section("").Key("TIME").RangeTimeFormat(time.RFC3339, time.Now(), minTime, maxTime) +vals = cfg.Section("").Key("TIME").RangeTime(time.Now(), minTime, maxTime) // RFC3339 +``` + +##### 自动分割键值到切片(slice) + +当存在无效输入时,使用零值代替: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> [0.0 2.2 0.0 0.0] +vals = cfg.Section("").Key("STRINGS").Strings(",") +vals = cfg.Section("").Key("FLOAT64S").Float64s(",") +vals = cfg.Section("").Key("INTS").Ints(",") +vals = cfg.Section("").Key("INT64S").Int64s(",") +vals = cfg.Section("").Key("UINTS").Uints(",") +vals = cfg.Section("").Key("UINT64S").Uint64s(",") +vals = cfg.Section("").Key("TIMES").Times(",") +``` + +从结果切片中剔除无效输入: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> [2.2] +vals = cfg.Section("").Key("FLOAT64S").ValidFloat64s(",") +vals = cfg.Section("").Key("INTS").ValidInts(",") +vals = cfg.Section("").Key("INT64S").ValidInt64s(",") +vals = cfg.Section("").Key("UINTS").ValidUints(",") +vals = cfg.Section("").Key("UINT64S").ValidUint64s(",") +vals = cfg.Section("").Key("TIMES").ValidTimes(",") +``` + +当存在无效输入时,直接返回错误: + +```go +// Input: 1.1, 2.2, 3.3, 4.4 -> [1.1 2.2 3.3 4.4] +// Input: how, 2.2, are, you -> error +vals = cfg.Section("").Key("FLOAT64S").StrictFloat64s(",") +vals = cfg.Section("").Key("INTS").StrictInts(",") +vals = cfg.Section("").Key("INT64S").StrictInt64s(",") +vals = cfg.Section("").Key("UINTS").StrictUints(",") +vals = cfg.Section("").Key("UINT64S").StrictUint64s(",") +vals = cfg.Section("").Key("TIMES").StrictTimes(",") +``` + +### 保存配置 + +终于到了这个时刻,是时候保存一下配置了。 + +比较原始的做法是输出配置到某个文件: + +```go +// ... +err = cfg.SaveTo("my.ini") +err = cfg.SaveToIndent("my.ini", "\t") +``` + +另一个比较高级的做法是写入到任何实现 `io.Writer` 接口的对象中: + +```go +// ... +cfg.WriteTo(writer) +cfg.WriteToIndent(writer, "\t") +``` + +默认情况下,空格将被用于对齐键值之间的等号以美化输出结果,以下代码可以禁用该功能: + +```go +ini.PrettyFormat = false +``` + +## 高级用法 + +### 递归读取键值 + +在获取所有键值的过程中,特殊语法 `%()s` 会被应用,其中 `` 可以是相同分区或者默认分区下的键名。字符串 `%()s` 会被相应的键值所替代,如果指定的键不存在,则会用空字符串替代。您可以最多使用 99 层的递归嵌套。 + +```ini +NAME = ini + +[author] +NAME = Unknwon +GITHUB = https://github.com/%(NAME)s + +[package] +FULL_NAME = github.com/go-ini/%(NAME)s +``` + +```go +cfg.Section("author").Key("GITHUB").String() // https://github.com/Unknwon +cfg.Section("package").Key("FULL_NAME").String() // github.com/go-ini/ini +``` + +### 读取父子分区 + +您可以在分区名称中使用 `.` 来表示两个或多个分区之间的父子关系。如果某个键在子分区中不存在,则会去它的父分区中再次寻找,直到没有父分区为止。 + +```ini +NAME = ini +VERSION = v1 +IMPORT_PATH = gopkg.in/%(NAME)s.%(VERSION)s + +[package] +CLONE_URL = https://%(IMPORT_PATH)s + +[package.sub] +``` + +```go +cfg.Section("package.sub").Key("CLONE_URL").String() // https://gopkg.in/ini.v1 +``` + +#### 获取上级父分区下的所有键名 + +```go +cfg.Section("package.sub").ParentKeys() // ["CLONE_URL"] +``` + +### 无法解析的分区 + +如果遇到一些比较特殊的分区,它们不包含常见的键值对,而是没有固定格式的纯文本,则可以使用 `LoadOptions.UnparsableSections` 进行处理: + +```go +cfg, err := LoadSources(LoadOptions{UnparseableSections: []string{"COMMENTS"}}, `[COMMENTS] +<1> This slide has the fuel listed in the wrong units `)) + +body := cfg.Section("COMMENTS").Body() + +/* --- start --- +<1> This slide has the fuel listed in the wrong units +------ end --- */ +``` + +### 读取自增键名 + +如果数据源中的键名为 `-`,则认为该键使用了自增键名的特殊语法。计数器从 1 开始,并且分区之间是相互独立的。 + +```ini +[features] +-: Support read/write comments of keys and sections +-: Support auto-increment of key names +-: Support load multiple files to overwrite key values +``` + +```go +cfg.Section("features").KeyStrings() // []{"#1", "#2", "#3"} +``` + +### 映射到结构 + +想要使用更加面向对象的方式玩转 INI 吗?好主意。 + +```ini +Name = Unknwon +age = 21 +Male = true +Born = 1993-01-01T20:17:05Z + +[Note] +Content = Hi is a good man! +Cities = HangZhou, Boston +``` + +```go +type Note struct { + Content string + Cities []string +} + +type Person struct { + Name string + Age int `ini:"age"` + Male bool + Born time.Time + Note + Created time.Time `ini:"-"` +} + +func main() { + cfg, err := ini.Load("path/to/ini") + // ... + p := new(Person) + err = cfg.MapTo(p) + // ... + + // 一切竟可以如此的简单。 + err = ini.MapTo(p, "path/to/ini") + // ... + + // 嗯哼?只需要映射一个分区吗? + n := new(Note) + err = cfg.Section("Note").MapTo(n) + // ... +} +``` + +结构的字段怎么设置默认值呢?很简单,只要在映射之前对指定字段进行赋值就可以了。如果键未找到或者类型错误,该值不会发生改变。 + +```go +// ... +p := &Person{ + Name: "Joe", +} +// ... +``` + +这样玩 INI 真的好酷啊!然而,如果不能还给我原来的配置文件,有什么卵用? + +### 从结构反射 + +可是,我有说不能吗? + +```go +type Embeded struct { + Dates []time.Time `delim:"|"` + Places []string `ini:"places,omitempty"` + None []int `ini:",omitempty"` +} + +type Author struct { + Name string `ini:"NAME"` + Male bool + Age int + GPA float64 + NeverMind string `ini:"-"` + *Embeded +} + +func main() { + a := &Author{"Unknwon", true, 21, 2.8, "", + &Embeded{ + []time.Time{time.Now(), time.Now()}, + []string{"HangZhou", "Boston"}, + []int{}, + }} + cfg := ini.Empty() + err = ini.ReflectFrom(cfg, a) + // ... +} +``` + +瞧瞧,奇迹发生了。 + +```ini +NAME = Unknwon +Male = true +Age = 21 +GPA = 2.8 + +[Embeded] +Dates = 2015-08-07T22:14:22+08:00|2015-08-07T22:14:22+08:00 +places = HangZhou,Boston +``` + +#### 名称映射器(Name Mapper) + +为了节省您的时间并简化代码,本库支持类型为 [`NameMapper`](https://gowalker.org/gopkg.in/ini.v1#NameMapper) 的名称映射器,该映射器负责结构字段名与分区名和键名之间的映射。 + +目前有 2 款内置的映射器: + +- `AllCapsUnderscore`:该映射器将字段名转换至格式 `ALL_CAPS_UNDERSCORE` 后再去匹配分区名和键名。 +- `TitleUnderscore`:该映射器将字段名转换至格式 `title_underscore` 后再去匹配分区名和键名。 + +使用方法: + +```go +type Info struct{ + PackageName string +} + +func main() { + err = ini.MapToWithMapper(&Info{}, ini.TitleUnderscore, []byte("package_name=ini")) + // ... + + cfg, err := ini.Load([]byte("PACKAGE_NAME=ini")) + // ... + info := new(Info) + cfg.NameMapper = ini.AllCapsUnderscore + err = cfg.MapTo(info) + // ... +} +``` + +使用函数 `ini.ReflectFromWithMapper` 时也可应用相同的规则。 + +#### 值映射器(Value Mapper) + +值映射器允许使用一个自定义函数自动展开值的具体内容,例如:运行时获取环境变量: + +```go +type Env struct { + Foo string `ini:"foo"` +} + +func main() { + cfg, err := ini.Load([]byte("[env]\nfoo = ${MY_VAR}\n") + cfg.ValueMapper = os.ExpandEnv + // ... + env := &Env{} + err = cfg.Section("env").MapTo(env) +} +``` + +本例中,`env.Foo` 将会是运行时所获取到环境变量 `MY_VAR` 的值。 + +#### 映射/反射的其它说明 + +任何嵌入的结构都会被默认认作一个不同的分区,并且不会自动产生所谓的父子分区关联: + +```go +type Child struct { + Age string +} + +type Parent struct { + Name string + Child +} + +type Config struct { + City string + Parent +} +``` + +示例配置文件: + +```ini +City = Boston + +[Parent] +Name = Unknwon + +[Child] +Age = 21 +``` + +很好,但是,我就是要嵌入结构也在同一个分区。好吧,你爹是李刚! + +```go +type Child struct { + Age string +} + +type Parent struct { + Name string + Child `ini:"Parent"` +} + +type Config struct { + City string + Parent +} +``` + +示例配置文件: + +```ini +City = Boston + +[Parent] +Name = Unknwon +Age = 21 +``` + +## 获取帮助 + +- [API 文档](https://gowalker.org/gopkg.in/ini.v1) +- [创建工单](https://github.com/go-ini/ini/issues/new) + +## 常见问题 + +### 字段 `BlockMode` 是什么? + +默认情况下,本库会在您进行读写操作时采用锁机制来确保数据时间。但在某些情况下,您非常确定只进行读操作。此时,您可以通过设置 `cfg.BlockMode = false` 来将读操作提升大约 **50-70%** 的性能。 + +### 为什么要写另一个 INI 解析库? + +许多人都在使用我的 [goconfig](https://github.com/Unknwon/goconfig) 来完成对 INI 文件的操作,但我希望使用更加 Go 风格的代码。并且当您设置 `cfg.BlockMode = false` 时,会有大约 **10-30%** 的性能提升。 + +为了做出这些改变,我必须对 API 进行破坏,所以新开一个仓库是最安全的做法。除此之外,本库直接使用 `gopkg.in` 来进行版本化发布。(其实真相是导入路径更短了) diff --git a/vendor/github.com/go-ini/ini/error.go b/vendor/github.com/go-ini/ini/error.go new file mode 100644 index 000000000..80afe7431 --- /dev/null +++ b/vendor/github.com/go-ini/ini/error.go @@ -0,0 +1,32 @@ +// Copyright 2016 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +package ini + +import ( + "fmt" +) + +type ErrDelimiterNotFound struct { + Line string +} + +func IsErrDelimiterNotFound(err error) bool { + _, ok := err.(ErrDelimiterNotFound) + return ok +} + +func (err ErrDelimiterNotFound) Error() string { + return fmt.Sprintf("key-value delimiter not found: %s", err.Line) +} diff --git a/vendor/github.com/go-ini/ini/ini.go b/vendor/github.com/go-ini/ini/ini.go new file mode 100644 index 000000000..68d73aa75 --- /dev/null +++ b/vendor/github.com/go-ini/ini/ini.go @@ -0,0 +1,549 @@ +// Copyright 2014 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +// Package ini provides INI file read and write functionality in Go. +package ini + +import ( + "bytes" + "errors" + "fmt" + "io" + "io/ioutil" + "os" + "regexp" + "runtime" + "strconv" + "strings" + "sync" + "time" +) + +const ( + // Name for default section. You can use this constant or the string literal. + // In most of cases, an empty string is all you need to access the section. + DEFAULT_SECTION = "DEFAULT" + + // Maximum allowed depth when recursively substituing variable names. + _DEPTH_VALUES = 99 + _VERSION = "1.25.4" +) + +// Version returns current package version literal. +func Version() string { + return _VERSION +} + +var ( + // Delimiter to determine or compose a new line. + // This variable will be changed to "\r\n" automatically on Windows + // at package init time. + LineBreak = "\n" + + // Variable regexp pattern: %(variable)s + varPattern = regexp.MustCompile(`%\(([^\)]+)\)s`) + + // Indicate whether to align "=" sign with spaces to produce pretty output + // or reduce all possible spaces for compact format. + PrettyFormat = true + + // Explicitly write DEFAULT section header + DefaultHeader = false +) + +func init() { + if runtime.GOOS == "windows" { + LineBreak = "\r\n" + } +} + +func inSlice(str string, s []string) bool { + for _, v := range s { + if str == v { + return true + } + } + return false +} + +// dataSource is an interface that returns object which can be read and closed. +type dataSource interface { + ReadCloser() (io.ReadCloser, error) +} + +// sourceFile represents an object that contains content on the local file system. +type sourceFile struct { + name string +} + +func (s sourceFile) ReadCloser() (_ io.ReadCloser, err error) { + return os.Open(s.name) +} + +type bytesReadCloser struct { + reader io.Reader +} + +func (rc *bytesReadCloser) Read(p []byte) (n int, err error) { + return rc.reader.Read(p) +} + +func (rc *bytesReadCloser) Close() error { + return nil +} + +// sourceData represents an object that contains content in memory. +type sourceData struct { + data []byte +} + +func (s *sourceData) ReadCloser() (io.ReadCloser, error) { + return ioutil.NopCloser(bytes.NewReader(s.data)), nil +} + +// sourceReadCloser represents an input stream with Close method. +type sourceReadCloser struct { + reader io.ReadCloser +} + +func (s *sourceReadCloser) ReadCloser() (io.ReadCloser, error) { + return s.reader, nil +} + +// File represents a combination of a or more INI file(s) in memory. +type File struct { + // Should make things safe, but sometimes doesn't matter. + BlockMode bool + // Make sure data is safe in multiple goroutines. + lock sync.RWMutex + + // Allow combination of multiple data sources. + dataSources []dataSource + // Actual data is stored here. + sections map[string]*Section + + // To keep data in order. + sectionList []string + + options LoadOptions + + NameMapper + ValueMapper +} + +// newFile initializes File object with given data sources. +func newFile(dataSources []dataSource, opts LoadOptions) *File { + return &File{ + BlockMode: true, + dataSources: dataSources, + sections: make(map[string]*Section), + sectionList: make([]string, 0, 10), + options: opts, + } +} + +func parseDataSource(source interface{}) (dataSource, error) { + switch s := source.(type) { + case string: + return sourceFile{s}, nil + case []byte: + return &sourceData{s}, nil + case io.ReadCloser: + return &sourceReadCloser{s}, nil + default: + return nil, fmt.Errorf("error parsing data source: unknown type '%s'", s) + } +} + +type LoadOptions struct { + // Loose indicates whether the parser should ignore nonexistent files or return error. + Loose bool + // Insensitive indicates whether the parser forces all section and key names to lowercase. + Insensitive bool + // IgnoreContinuation indicates whether to ignore continuation lines while parsing. + IgnoreContinuation bool + // AllowBooleanKeys indicates whether to allow boolean type keys or treat as value is missing. + // This type of keys are mostly used in my.cnf. + AllowBooleanKeys bool + // AllowShadows indicates whether to keep track of keys with same name under same section. + AllowShadows bool + // Some INI formats allow group blocks that store a block of raw content that doesn't otherwise + // conform to key/value pairs. Specify the names of those blocks here. + UnparseableSections []string +} + +func LoadSources(opts LoadOptions, source interface{}, others ...interface{}) (_ *File, err error) { + sources := make([]dataSource, len(others)+1) + sources[0], err = parseDataSource(source) + if err != nil { + return nil, err + } + for i := range others { + sources[i+1], err = parseDataSource(others[i]) + if err != nil { + return nil, err + } + } + f := newFile(sources, opts) + if err = f.Reload(); err != nil { + return nil, err + } + return f, nil +} + +// Load loads and parses from INI data sources. +// Arguments can be mixed of file name with string type, or raw data in []byte. +// It will return error if list contains nonexistent files. +func Load(source interface{}, others ...interface{}) (*File, error) { + return LoadSources(LoadOptions{}, source, others...) +} + +// LooseLoad has exactly same functionality as Load function +// except it ignores nonexistent files instead of returning error. +func LooseLoad(source interface{}, others ...interface{}) (*File, error) { + return LoadSources(LoadOptions{Loose: true}, source, others...) +} + +// InsensitiveLoad has exactly same functionality as Load function +// except it forces all section and key names to be lowercased. +func InsensitiveLoad(source interface{}, others ...interface{}) (*File, error) { + return LoadSources(LoadOptions{Insensitive: true}, source, others...) +} + +// InsensitiveLoad has exactly same functionality as Load function +// except it allows have shadow keys. +func ShadowLoad(source interface{}, others ...interface{}) (*File, error) { + return LoadSources(LoadOptions{AllowShadows: true}, source, others...) +} + +// Empty returns an empty file object. +func Empty() *File { + // Ignore error here, we sure our data is good. + f, _ := Load([]byte("")) + return f +} + +// NewSection creates a new section. +func (f *File) NewSection(name string) (*Section, error) { + if len(name) == 0 { + return nil, errors.New("error creating new section: empty section name") + } else if f.options.Insensitive && name != DEFAULT_SECTION { + name = strings.ToLower(name) + } + + if f.BlockMode { + f.lock.Lock() + defer f.lock.Unlock() + } + + if inSlice(name, f.sectionList) { + return f.sections[name], nil + } + + f.sectionList = append(f.sectionList, name) + f.sections[name] = newSection(f, name) + return f.sections[name], nil +} + +// NewRawSection creates a new section with an unparseable body. +func (f *File) NewRawSection(name, body string) (*Section, error) { + section, err := f.NewSection(name) + if err != nil { + return nil, err + } + + section.isRawSection = true + section.rawBody = body + return section, nil +} + +// NewSections creates a list of sections. +func (f *File) NewSections(names ...string) (err error) { + for _, name := range names { + if _, err = f.NewSection(name); err != nil { + return err + } + } + return nil +} + +// GetSection returns section by given name. +func (f *File) GetSection(name string) (*Section, error) { + if len(name) == 0 { + name = DEFAULT_SECTION + } else if f.options.Insensitive { + name = strings.ToLower(name) + } + + if f.BlockMode { + f.lock.RLock() + defer f.lock.RUnlock() + } + + sec := f.sections[name] + if sec == nil { + return nil, fmt.Errorf("section '%s' does not exist", name) + } + return sec, nil +} + +// Section assumes named section exists and returns a zero-value when not. +func (f *File) Section(name string) *Section { + sec, err := f.GetSection(name) + if err != nil { + // Note: It's OK here because the only possible error is empty section name, + // but if it's empty, this piece of code won't be executed. + sec, _ = f.NewSection(name) + return sec + } + return sec +} + +// Section returns list of Section. +func (f *File) Sections() []*Section { + sections := make([]*Section, len(f.sectionList)) + for i := range f.sectionList { + sections[i] = f.Section(f.sectionList[i]) + } + return sections +} + +// SectionStrings returns list of section names. +func (f *File) SectionStrings() []string { + list := make([]string, len(f.sectionList)) + copy(list, f.sectionList) + return list +} + +// DeleteSection deletes a section. +func (f *File) DeleteSection(name string) { + if f.BlockMode { + f.lock.Lock() + defer f.lock.Unlock() + } + + if len(name) == 0 { + name = DEFAULT_SECTION + } + + for i, s := range f.sectionList { + if s == name { + f.sectionList = append(f.sectionList[:i], f.sectionList[i+1:]...) + delete(f.sections, name) + return + } + } +} + +func (f *File) reload(s dataSource) error { + r, err := s.ReadCloser() + if err != nil { + return err + } + defer r.Close() + + return f.parse(r) +} + +// Reload reloads and parses all data sources. +func (f *File) Reload() (err error) { + for _, s := range f.dataSources { + if err = f.reload(s); err != nil { + // In loose mode, we create an empty default section for nonexistent files. + if os.IsNotExist(err) && f.options.Loose { + f.parse(bytes.NewBuffer(nil)) + continue + } + return err + } + } + return nil +} + +// Append appends one or more data sources and reloads automatically. +func (f *File) Append(source interface{}, others ...interface{}) error { + ds, err := parseDataSource(source) + if err != nil { + return err + } + f.dataSources = append(f.dataSources, ds) + for _, s := range others { + ds, err = parseDataSource(s) + if err != nil { + return err + } + f.dataSources = append(f.dataSources, ds) + } + return f.Reload() +} + +// WriteToIndent writes content into io.Writer with given indention. +// If PrettyFormat has been set to be true, +// it will align "=" sign with spaces under each section. +func (f *File) WriteToIndent(w io.Writer, indent string) (n int64, err error) { + equalSign := "=" + if PrettyFormat { + equalSign = " = " + } + + // Use buffer to make sure target is safe until finish encoding. + buf := bytes.NewBuffer(nil) + for i, sname := range f.sectionList { + sec := f.Section(sname) + if len(sec.Comment) > 0 { + if sec.Comment[0] != '#' && sec.Comment[0] != ';' { + sec.Comment = "; " + sec.Comment + } + if _, err = buf.WriteString(sec.Comment + LineBreak); err != nil { + return 0, err + } + } + + if i > 0 || DefaultHeader { + if _, err = buf.WriteString("[" + sname + "]" + LineBreak); err != nil { + return 0, err + } + } else { + // Write nothing if default section is empty + if len(sec.keyList) == 0 { + continue + } + } + + if sec.isRawSection { + if _, err = buf.WriteString(sec.rawBody); err != nil { + return 0, err + } + continue + } + + // Count and generate alignment length and buffer spaces using the + // longest key. Keys may be modifed if they contain certain characters so + // we need to take that into account in our calculation. + alignLength := 0 + if PrettyFormat { + for _, kname := range sec.keyList { + keyLength := len(kname) + // First case will surround key by ` and second by """ + if strings.ContainsAny(kname, "\"=:") { + keyLength += 2 + } else if strings.Contains(kname, "`") { + keyLength += 6 + } + + if keyLength > alignLength { + alignLength = keyLength + } + } + } + alignSpaces := bytes.Repeat([]byte(" "), alignLength) + + KEY_LIST: + for _, kname := range sec.keyList { + key := sec.Key(kname) + if len(key.Comment) > 0 { + if len(indent) > 0 && sname != DEFAULT_SECTION { + buf.WriteString(indent) + } + if key.Comment[0] != '#' && key.Comment[0] != ';' { + key.Comment = "; " + key.Comment + } + if _, err = buf.WriteString(key.Comment + LineBreak); err != nil { + return 0, err + } + } + + if len(indent) > 0 && sname != DEFAULT_SECTION { + buf.WriteString(indent) + } + + switch { + case key.isAutoIncrement: + kname = "-" + case strings.ContainsAny(kname, "\"=:"): + kname = "`" + kname + "`" + case strings.Contains(kname, "`"): + kname = `"""` + kname + `"""` + } + + for _, val := range key.ValueWithShadows() { + if _, err = buf.WriteString(kname); err != nil { + return 0, err + } + + if key.isBooleanType { + if kname != sec.keyList[len(sec.keyList)-1] { + buf.WriteString(LineBreak) + } + continue KEY_LIST + } + + // Write out alignment spaces before "=" sign + if PrettyFormat { + buf.Write(alignSpaces[:alignLength-len(kname)]) + } + + // In case key value contains "\n", "`", "\"", "#" or ";" + if strings.ContainsAny(val, "\n`") { + val = `"""` + val + `"""` + } else if strings.ContainsAny(val, "#;") { + val = "`" + val + "`" + } + if _, err = buf.WriteString(equalSign + val + LineBreak); err != nil { + return 0, err + } + } + } + + // Put a line between sections + if _, err = buf.WriteString(LineBreak); err != nil { + return 0, err + } + } + + return buf.WriteTo(w) +} + +// WriteTo writes file content into io.Writer. +func (f *File) WriteTo(w io.Writer) (int64, error) { + return f.WriteToIndent(w, "") +} + +// SaveToIndent writes content to file system with given value indention. +func (f *File) SaveToIndent(filename, indent string) error { + // Note: Because we are truncating with os.Create, + // so it's safer to save to a temporary file location and rename afte done. + tmpPath := filename + "." + strconv.Itoa(time.Now().Nanosecond()) + ".tmp" + defer os.Remove(tmpPath) + + fw, err := os.Create(tmpPath) + if err != nil { + return err + } + + if _, err = f.WriteToIndent(fw, indent); err != nil { + fw.Close() + return err + } + fw.Close() + + // Remove old file and rename the new one. + os.Remove(filename) + return os.Rename(tmpPath, filename) +} + +// SaveTo writes content to file system. +func (f *File) SaveTo(filename string) error { + return f.SaveToIndent(filename, "") +} diff --git a/vendor/github.com/go-ini/ini/key.go b/vendor/github.com/go-ini/ini/key.go new file mode 100644 index 000000000..852696f4c --- /dev/null +++ b/vendor/github.com/go-ini/ini/key.go @@ -0,0 +1,703 @@ +// Copyright 2014 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +package ini + +import ( + "errors" + "fmt" + "strconv" + "strings" + "time" +) + +// Key represents a key under a section. +type Key struct { + s *Section + name string + value string + isAutoIncrement bool + isBooleanType bool + + isShadow bool + shadows []*Key + + Comment string +} + +// newKey simply return a key object with given values. +func newKey(s *Section, name, val string) *Key { + return &Key{ + s: s, + name: name, + value: val, + } +} + +func (k *Key) addShadow(val string) error { + if k.isShadow { + return errors.New("cannot add shadow to another shadow key") + } else if k.isAutoIncrement || k.isBooleanType { + return errors.New("cannot add shadow to auto-increment or boolean key") + } + + shadow := newKey(k.s, k.name, val) + shadow.isShadow = true + k.shadows = append(k.shadows, shadow) + return nil +} + +// AddShadow adds a new shadow key to itself. +func (k *Key) AddShadow(val string) error { + if !k.s.f.options.AllowShadows { + return errors.New("shadow key is not allowed") + } + return k.addShadow(val) +} + +// ValueMapper represents a mapping function for values, e.g. os.ExpandEnv +type ValueMapper func(string) string + +// Name returns name of key. +func (k *Key) Name() string { + return k.name +} + +// Value returns raw value of key for performance purpose. +func (k *Key) Value() string { + return k.value +} + +// ValueWithShadows returns raw values of key and its shadows if any. +func (k *Key) ValueWithShadows() []string { + if len(k.shadows) == 0 { + return []string{k.value} + } + vals := make([]string, len(k.shadows)+1) + vals[0] = k.value + for i := range k.shadows { + vals[i+1] = k.shadows[i].value + } + return vals +} + +// transformValue takes a raw value and transforms to its final string. +func (k *Key) transformValue(val string) string { + if k.s.f.ValueMapper != nil { + val = k.s.f.ValueMapper(val) + } + + // Fail-fast if no indicate char found for recursive value + if !strings.Contains(val, "%") { + return val + } + for i := 0; i < _DEPTH_VALUES; i++ { + vr := varPattern.FindString(val) + if len(vr) == 0 { + break + } + + // Take off leading '%(' and trailing ')s'. + noption := strings.TrimLeft(vr, "%(") + noption = strings.TrimRight(noption, ")s") + + // Search in the same section. + nk, err := k.s.GetKey(noption) + if err != nil { + // Search again in default section. + nk, _ = k.s.f.Section("").GetKey(noption) + } + + // Substitute by new value and take off leading '%(' and trailing ')s'. + val = strings.Replace(val, vr, nk.value, -1) + } + return val +} + +// String returns string representation of value. +func (k *Key) String() string { + return k.transformValue(k.value) +} + +// Validate accepts a validate function which can +// return modifed result as key value. +func (k *Key) Validate(fn func(string) string) string { + return fn(k.String()) +} + +// parseBool returns the boolean value represented by the string. +// +// It accepts 1, t, T, TRUE, true, True, YES, yes, Yes, y, ON, on, On, +// 0, f, F, FALSE, false, False, NO, no, No, n, OFF, off, Off. +// Any other value returns an error. +func parseBool(str string) (value bool, err error) { + switch str { + case "1", "t", "T", "true", "TRUE", "True", "YES", "yes", "Yes", "y", "ON", "on", "On": + return true, nil + case "0", "f", "F", "false", "FALSE", "False", "NO", "no", "No", "n", "OFF", "off", "Off": + return false, nil + } + return false, fmt.Errorf("parsing \"%s\": invalid syntax", str) +} + +// Bool returns bool type value. +func (k *Key) Bool() (bool, error) { + return parseBool(k.String()) +} + +// Float64 returns float64 type value. +func (k *Key) Float64() (float64, error) { + return strconv.ParseFloat(k.String(), 64) +} + +// Int returns int type value. +func (k *Key) Int() (int, error) { + return strconv.Atoi(k.String()) +} + +// Int64 returns int64 type value. +func (k *Key) Int64() (int64, error) { + return strconv.ParseInt(k.String(), 10, 64) +} + +// Uint returns uint type valued. +func (k *Key) Uint() (uint, error) { + u, e := strconv.ParseUint(k.String(), 10, 64) + return uint(u), e +} + +// Uint64 returns uint64 type value. +func (k *Key) Uint64() (uint64, error) { + return strconv.ParseUint(k.String(), 10, 64) +} + +// Duration returns time.Duration type value. +func (k *Key) Duration() (time.Duration, error) { + return time.ParseDuration(k.String()) +} + +// TimeFormat parses with given format and returns time.Time type value. +func (k *Key) TimeFormat(format string) (time.Time, error) { + return time.Parse(format, k.String()) +} + +// Time parses with RFC3339 format and returns time.Time type value. +func (k *Key) Time() (time.Time, error) { + return k.TimeFormat(time.RFC3339) +} + +// MustString returns default value if key value is empty. +func (k *Key) MustString(defaultVal string) string { + val := k.String() + if len(val) == 0 { + k.value = defaultVal + return defaultVal + } + return val +} + +// MustBool always returns value without error, +// it returns false if error occurs. +func (k *Key) MustBool(defaultVal ...bool) bool { + val, err := k.Bool() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatBool(defaultVal[0]) + return defaultVal[0] + } + return val +} + +// MustFloat64 always returns value without error, +// it returns 0.0 if error occurs. +func (k *Key) MustFloat64(defaultVal ...float64) float64 { + val, err := k.Float64() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatFloat(defaultVal[0], 'f', -1, 64) + return defaultVal[0] + } + return val +} + +// MustInt always returns value without error, +// it returns 0 if error occurs. +func (k *Key) MustInt(defaultVal ...int) int { + val, err := k.Int() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatInt(int64(defaultVal[0]), 10) + return defaultVal[0] + } + return val +} + +// MustInt64 always returns value without error, +// it returns 0 if error occurs. +func (k *Key) MustInt64(defaultVal ...int64) int64 { + val, err := k.Int64() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatInt(defaultVal[0], 10) + return defaultVal[0] + } + return val +} + +// MustUint always returns value without error, +// it returns 0 if error occurs. +func (k *Key) MustUint(defaultVal ...uint) uint { + val, err := k.Uint() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatUint(uint64(defaultVal[0]), 10) + return defaultVal[0] + } + return val +} + +// MustUint64 always returns value without error, +// it returns 0 if error occurs. +func (k *Key) MustUint64(defaultVal ...uint64) uint64 { + val, err := k.Uint64() + if len(defaultVal) > 0 && err != nil { + k.value = strconv.FormatUint(defaultVal[0], 10) + return defaultVal[0] + } + return val +} + +// MustDuration always returns value without error, +// it returns zero value if error occurs. +func (k *Key) MustDuration(defaultVal ...time.Duration) time.Duration { + val, err := k.Duration() + if len(defaultVal) > 0 && err != nil { + k.value = defaultVal[0].String() + return defaultVal[0] + } + return val +} + +// MustTimeFormat always parses with given format and returns value without error, +// it returns zero value if error occurs. +func (k *Key) MustTimeFormat(format string, defaultVal ...time.Time) time.Time { + val, err := k.TimeFormat(format) + if len(defaultVal) > 0 && err != nil { + k.value = defaultVal[0].Format(format) + return defaultVal[0] + } + return val +} + +// MustTime always parses with RFC3339 format and returns value without error, +// it returns zero value if error occurs. +func (k *Key) MustTime(defaultVal ...time.Time) time.Time { + return k.MustTimeFormat(time.RFC3339, defaultVal...) +} + +// In always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) In(defaultVal string, candidates []string) string { + val := k.String() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InFloat64 always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InFloat64(defaultVal float64, candidates []float64) float64 { + val := k.MustFloat64() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InInt always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InInt(defaultVal int, candidates []int) int { + val := k.MustInt() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InInt64 always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InInt64(defaultVal int64, candidates []int64) int64 { + val := k.MustInt64() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InUint always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InUint(defaultVal uint, candidates []uint) uint { + val := k.MustUint() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InUint64 always returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InUint64(defaultVal uint64, candidates []uint64) uint64 { + val := k.MustUint64() + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InTimeFormat always parses with given format and returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InTimeFormat(format string, defaultVal time.Time, candidates []time.Time) time.Time { + val := k.MustTimeFormat(format) + for _, cand := range candidates { + if val == cand { + return val + } + } + return defaultVal +} + +// InTime always parses with RFC3339 format and returns value without error, +// it returns default value if error occurs or doesn't fit into candidates. +func (k *Key) InTime(defaultVal time.Time, candidates []time.Time) time.Time { + return k.InTimeFormat(time.RFC3339, defaultVal, candidates) +} + +// RangeFloat64 checks if value is in given range inclusively, +// and returns default value if it's not. +func (k *Key) RangeFloat64(defaultVal, min, max float64) float64 { + val := k.MustFloat64() + if val < min || val > max { + return defaultVal + } + return val +} + +// RangeInt checks if value is in given range inclusively, +// and returns default value if it's not. +func (k *Key) RangeInt(defaultVal, min, max int) int { + val := k.MustInt() + if val < min || val > max { + return defaultVal + } + return val +} + +// RangeInt64 checks if value is in given range inclusively, +// and returns default value if it's not. +func (k *Key) RangeInt64(defaultVal, min, max int64) int64 { + val := k.MustInt64() + if val < min || val > max { + return defaultVal + } + return val +} + +// RangeTimeFormat checks if value with given format is in given range inclusively, +// and returns default value if it's not. +func (k *Key) RangeTimeFormat(format string, defaultVal, min, max time.Time) time.Time { + val := k.MustTimeFormat(format) + if val.Unix() < min.Unix() || val.Unix() > max.Unix() { + return defaultVal + } + return val +} + +// RangeTime checks if value with RFC3339 format is in given range inclusively, +// and returns default value if it's not. +func (k *Key) RangeTime(defaultVal, min, max time.Time) time.Time { + return k.RangeTimeFormat(time.RFC3339, defaultVal, min, max) +} + +// Strings returns list of string divided by given delimiter. +func (k *Key) Strings(delim string) []string { + str := k.String() + if len(str) == 0 { + return []string{} + } + + vals := strings.Split(str, delim) + for i := range vals { + // vals[i] = k.transformValue(strings.TrimSpace(vals[i])) + vals[i] = strings.TrimSpace(vals[i]) + } + return vals +} + +// StringsWithShadows returns list of string divided by given delimiter. +// Shadows will also be appended if any. +func (k *Key) StringsWithShadows(delim string) []string { + vals := k.ValueWithShadows() + results := make([]string, 0, len(vals)*2) + for i := range vals { + if len(vals) == 0 { + continue + } + + results = append(results, strings.Split(vals[i], delim)...) + } + + for i := range results { + results[i] = k.transformValue(strings.TrimSpace(results[i])) + } + return results +} + +// Float64s returns list of float64 divided by given delimiter. Any invalid input will be treated as zero value. +func (k *Key) Float64s(delim string) []float64 { + vals, _ := k.getFloat64s(delim, true, false) + return vals +} + +// Ints returns list of int divided by given delimiter. Any invalid input will be treated as zero value. +func (k *Key) Ints(delim string) []int { + vals, _ := k.parseInts(k.Strings(delim), true, false) + return vals +} + +// Int64s returns list of int64 divided by given delimiter. Any invalid input will be treated as zero value. +func (k *Key) Int64s(delim string) []int64 { + vals, _ := k.parseInt64s(k.Strings(delim), true, false) + return vals +} + +// Uints returns list of uint divided by given delimiter. Any invalid input will be treated as zero value. +func (k *Key) Uints(delim string) []uint { + vals, _ := k.getUints(delim, true, false) + return vals +} + +// Uint64s returns list of uint64 divided by given delimiter. Any invalid input will be treated as zero value. +func (k *Key) Uint64s(delim string) []uint64 { + vals, _ := k.getUint64s(delim, true, false) + return vals +} + +// TimesFormat parses with given format and returns list of time.Time divided by given delimiter. +// Any invalid input will be treated as zero value (0001-01-01 00:00:00 +0000 UTC). +func (k *Key) TimesFormat(format, delim string) []time.Time { + vals, _ := k.getTimesFormat(format, delim, true, false) + return vals +} + +// Times parses with RFC3339 format and returns list of time.Time divided by given delimiter. +// Any invalid input will be treated as zero value (0001-01-01 00:00:00 +0000 UTC). +func (k *Key) Times(delim string) []time.Time { + return k.TimesFormat(time.RFC3339, delim) +} + +// ValidFloat64s returns list of float64 divided by given delimiter. If some value is not float, then +// it will not be included to result list. +func (k *Key) ValidFloat64s(delim string) []float64 { + vals, _ := k.getFloat64s(delim, false, false) + return vals +} + +// ValidInts returns list of int divided by given delimiter. If some value is not integer, then it will +// not be included to result list. +func (k *Key) ValidInts(delim string) []int { + vals, _ := k.parseInts(k.Strings(delim), false, false) + return vals +} + +// ValidInt64s returns list of int64 divided by given delimiter. If some value is not 64-bit integer, +// then it will not be included to result list. +func (k *Key) ValidInt64s(delim string) []int64 { + vals, _ := k.parseInt64s(k.Strings(delim), false, false) + return vals +} + +// ValidUints returns list of uint divided by given delimiter. If some value is not unsigned integer, +// then it will not be included to result list. +func (k *Key) ValidUints(delim string) []uint { + vals, _ := k.getUints(delim, false, false) + return vals +} + +// ValidUint64s returns list of uint64 divided by given delimiter. If some value is not 64-bit unsigned +// integer, then it will not be included to result list. +func (k *Key) ValidUint64s(delim string) []uint64 { + vals, _ := k.getUint64s(delim, false, false) + return vals +} + +// ValidTimesFormat parses with given format and returns list of time.Time divided by given delimiter. +func (k *Key) ValidTimesFormat(format, delim string) []time.Time { + vals, _ := k.getTimesFormat(format, delim, false, false) + return vals +} + +// ValidTimes parses with RFC3339 format and returns list of time.Time divided by given delimiter. +func (k *Key) ValidTimes(delim string) []time.Time { + return k.ValidTimesFormat(time.RFC3339, delim) +} + +// StrictFloat64s returns list of float64 divided by given delimiter or error on first invalid input. +func (k *Key) StrictFloat64s(delim string) ([]float64, error) { + return k.getFloat64s(delim, false, true) +} + +// StrictInts returns list of int divided by given delimiter or error on first invalid input. +func (k *Key) StrictInts(delim string) ([]int, error) { + return k.parseInts(k.Strings(delim), false, true) +} + +// StrictInt64s returns list of int64 divided by given delimiter or error on first invalid input. +func (k *Key) StrictInt64s(delim string) ([]int64, error) { + return k.parseInt64s(k.Strings(delim), false, true) +} + +// StrictUints returns list of uint divided by given delimiter or error on first invalid input. +func (k *Key) StrictUints(delim string) ([]uint, error) { + return k.getUints(delim, false, true) +} + +// StrictUint64s returns list of uint64 divided by given delimiter or error on first invalid input. +func (k *Key) StrictUint64s(delim string) ([]uint64, error) { + return k.getUint64s(delim, false, true) +} + +// StrictTimesFormat parses with given format and returns list of time.Time divided by given delimiter +// or error on first invalid input. +func (k *Key) StrictTimesFormat(format, delim string) ([]time.Time, error) { + return k.getTimesFormat(format, delim, false, true) +} + +// StrictTimes parses with RFC3339 format and returns list of time.Time divided by given delimiter +// or error on first invalid input. +func (k *Key) StrictTimes(delim string) ([]time.Time, error) { + return k.StrictTimesFormat(time.RFC3339, delim) +} + +// getFloat64s returns list of float64 divided by given delimiter. +func (k *Key) getFloat64s(delim string, addInvalid, returnOnInvalid bool) ([]float64, error) { + strs := k.Strings(delim) + vals := make([]float64, 0, len(strs)) + for _, str := range strs { + val, err := strconv.ParseFloat(str, 64) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, val) + } + } + return vals, nil +} + +// parseInts transforms strings to ints. +func (k *Key) parseInts(strs []string, addInvalid, returnOnInvalid bool) ([]int, error) { + vals := make([]int, 0, len(strs)) + for _, str := range strs { + val, err := strconv.Atoi(str) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, val) + } + } + return vals, nil +} + +// parseInt64s transforms strings to int64s. +func (k *Key) parseInt64s(strs []string, addInvalid, returnOnInvalid bool) ([]int64, error) { + vals := make([]int64, 0, len(strs)) + for _, str := range strs { + val, err := strconv.ParseInt(str, 10, 64) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, val) + } + } + return vals, nil +} + +// getUints returns list of uint divided by given delimiter. +func (k *Key) getUints(delim string, addInvalid, returnOnInvalid bool) ([]uint, error) { + strs := k.Strings(delim) + vals := make([]uint, 0, len(strs)) + for _, str := range strs { + val, err := strconv.ParseUint(str, 10, 0) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, uint(val)) + } + } + return vals, nil +} + +// getUint64s returns list of uint64 divided by given delimiter. +func (k *Key) getUint64s(delim string, addInvalid, returnOnInvalid bool) ([]uint64, error) { + strs := k.Strings(delim) + vals := make([]uint64, 0, len(strs)) + for _, str := range strs { + val, err := strconv.ParseUint(str, 10, 64) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, val) + } + } + return vals, nil +} + +// getTimesFormat parses with given format and returns list of time.Time divided by given delimiter. +func (k *Key) getTimesFormat(format, delim string, addInvalid, returnOnInvalid bool) ([]time.Time, error) { + strs := k.Strings(delim) + vals := make([]time.Time, 0, len(strs)) + for _, str := range strs { + val, err := time.Parse(format, str) + if err != nil && returnOnInvalid { + return nil, err + } + if err == nil || addInvalid { + vals = append(vals, val) + } + } + return vals, nil +} + +// SetValue changes key value. +func (k *Key) SetValue(v string) { + if k.s.f.BlockMode { + k.s.f.lock.Lock() + defer k.s.f.lock.Unlock() + } + + k.value = v + k.s.keysHash[k.name] = v +} diff --git a/vendor/github.com/go-ini/ini/parser.go b/vendor/github.com/go-ini/ini/parser.go new file mode 100644 index 000000000..673ef80ca --- /dev/null +++ b/vendor/github.com/go-ini/ini/parser.go @@ -0,0 +1,358 @@ +// Copyright 2015 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +package ini + +import ( + "bufio" + "bytes" + "fmt" + "io" + "strconv" + "strings" + "unicode" +) + +type tokenType int + +const ( + _TOKEN_INVALID tokenType = iota + _TOKEN_COMMENT + _TOKEN_SECTION + _TOKEN_KEY +) + +type parser struct { + buf *bufio.Reader + isEOF bool + count int + comment *bytes.Buffer +} + +func newParser(r io.Reader) *parser { + return &parser{ + buf: bufio.NewReader(r), + count: 1, + comment: &bytes.Buffer{}, + } +} + +// BOM handles header of UTF-8, UTF-16 LE and UTF-16 BE's BOM format. +// http://en.wikipedia.org/wiki/Byte_order_mark#Representations_of_byte_order_marks_by_encoding +func (p *parser) BOM() error { + mask, err := p.buf.Peek(2) + if err != nil && err != io.EOF { + return err + } else if len(mask) < 2 { + return nil + } + + switch { + case mask[0] == 254 && mask[1] == 255: + fallthrough + case mask[0] == 255 && mask[1] == 254: + p.buf.Read(mask) + case mask[0] == 239 && mask[1] == 187: + mask, err := p.buf.Peek(3) + if err != nil && err != io.EOF { + return err + } else if len(mask) < 3 { + return nil + } + if mask[2] == 191 { + p.buf.Read(mask) + } + } + return nil +} + +func (p *parser) readUntil(delim byte) ([]byte, error) { + data, err := p.buf.ReadBytes(delim) + if err != nil { + if err == io.EOF { + p.isEOF = true + } else { + return nil, err + } + } + return data, nil +} + +func cleanComment(in []byte) ([]byte, bool) { + i := bytes.IndexAny(in, "#;") + if i == -1 { + return nil, false + } + return in[i:], true +} + +func readKeyName(in []byte) (string, int, error) { + line := string(in) + + // Check if key name surrounded by quotes. + var keyQuote string + if line[0] == '"' { + if len(line) > 6 && string(line[0:3]) == `"""` { + keyQuote = `"""` + } else { + keyQuote = `"` + } + } else if line[0] == '`' { + keyQuote = "`" + } + + // Get out key name + endIdx := -1 + if len(keyQuote) > 0 { + startIdx := len(keyQuote) + // FIXME: fail case -> """"""name"""=value + pos := strings.Index(line[startIdx:], keyQuote) + if pos == -1 { + return "", -1, fmt.Errorf("missing closing key quote: %s", line) + } + pos += startIdx + + // Find key-value delimiter + i := strings.IndexAny(line[pos+startIdx:], "=:") + if i < 0 { + return "", -1, ErrDelimiterNotFound{line} + } + endIdx = pos + i + return strings.TrimSpace(line[startIdx:pos]), endIdx + startIdx + 1, nil + } + + endIdx = strings.IndexAny(line, "=:") + if endIdx < 0 { + return "", -1, ErrDelimiterNotFound{line} + } + return strings.TrimSpace(line[0:endIdx]), endIdx + 1, nil +} + +func (p *parser) readMultilines(line, val, valQuote string) (string, error) { + for { + data, err := p.readUntil('\n') + if err != nil { + return "", err + } + next := string(data) + + pos := strings.LastIndex(next, valQuote) + if pos > -1 { + val += next[:pos] + + comment, has := cleanComment([]byte(next[pos:])) + if has { + p.comment.Write(bytes.TrimSpace(comment)) + } + break + } + val += next + if p.isEOF { + return "", fmt.Errorf("missing closing key quote from '%s' to '%s'", line, next) + } + } + return val, nil +} + +func (p *parser) readContinuationLines(val string) (string, error) { + for { + data, err := p.readUntil('\n') + if err != nil { + return "", err + } + next := strings.TrimSpace(string(data)) + + if len(next) == 0 { + break + } + val += next + if val[len(val)-1] != '\\' { + break + } + val = val[:len(val)-1] + } + return val, nil +} + +// hasSurroundedQuote check if and only if the first and last characters +// are quotes \" or \'. +// It returns false if any other parts also contain same kind of quotes. +func hasSurroundedQuote(in string, quote byte) bool { + return len(in) > 2 && in[0] == quote && in[len(in)-1] == quote && + strings.IndexByte(in[1:], quote) == len(in)-2 +} + +func (p *parser) readValue(in []byte, ignoreContinuation bool) (string, error) { + line := strings.TrimLeftFunc(string(in), unicode.IsSpace) + if len(line) == 0 { + return "", nil + } + + var valQuote string + if len(line) > 3 && string(line[0:3]) == `"""` { + valQuote = `"""` + } else if line[0] == '`' { + valQuote = "`" + } + + if len(valQuote) > 0 { + startIdx := len(valQuote) + pos := strings.LastIndex(line[startIdx:], valQuote) + // Check for multi-line value + if pos == -1 { + return p.readMultilines(line, line[startIdx:], valQuote) + } + + return line[startIdx : pos+startIdx], nil + } + + // Won't be able to reach here if value only contains whitespace. + line = strings.TrimSpace(line) + + // Check continuation lines when desired. + if !ignoreContinuation && line[len(line)-1] == '\\' { + return p.readContinuationLines(line[:len(line)-1]) + } + + i := strings.IndexAny(line, "#;") + if i > -1 { + p.comment.WriteString(line[i:]) + line = strings.TrimSpace(line[:i]) + } + + // Trim single quotes + if hasSurroundedQuote(line, '\'') || + hasSurroundedQuote(line, '"') { + line = line[1 : len(line)-1] + } + return line, nil +} + +// parse parses data through an io.Reader. +func (f *File) parse(reader io.Reader) (err error) { + p := newParser(reader) + if err = p.BOM(); err != nil { + return fmt.Errorf("BOM: %v", err) + } + + // Ignore error because default section name is never empty string. + section, _ := f.NewSection(DEFAULT_SECTION) + + var line []byte + var inUnparseableSection bool + for !p.isEOF { + line, err = p.readUntil('\n') + if err != nil { + return err + } + + line = bytes.TrimLeftFunc(line, unicode.IsSpace) + if len(line) == 0 { + continue + } + + // Comments + if line[0] == '#' || line[0] == ';' { + // Note: we do not care ending line break, + // it is needed for adding second line, + // so just clean it once at the end when set to value. + p.comment.Write(line) + continue + } + + // Section + if line[0] == '[' { + // Read to the next ']' (TODO: support quoted strings) + // TODO(unknwon): use LastIndexByte when stop supporting Go1.4 + closeIdx := bytes.LastIndex(line, []byte("]")) + if closeIdx == -1 { + return fmt.Errorf("unclosed section: %s", line) + } + + name := string(line[1:closeIdx]) + section, err = f.NewSection(name) + if err != nil { + return err + } + + comment, has := cleanComment(line[closeIdx+1:]) + if has { + p.comment.Write(comment) + } + + section.Comment = strings.TrimSpace(p.comment.String()) + + // Reset aotu-counter and comments + p.comment.Reset() + p.count = 1 + + inUnparseableSection = false + for i := range f.options.UnparseableSections { + if f.options.UnparseableSections[i] == name || + (f.options.Insensitive && strings.ToLower(f.options.UnparseableSections[i]) == strings.ToLower(name)) { + inUnparseableSection = true + continue + } + } + continue + } + + if inUnparseableSection { + section.isRawSection = true + section.rawBody += string(line) + continue + } + + kname, offset, err := readKeyName(line) + if err != nil { + // Treat as boolean key when desired, and whole line is key name. + if IsErrDelimiterNotFound(err) && f.options.AllowBooleanKeys { + kname, err := p.readValue(line, f.options.IgnoreContinuation) + if err != nil { + return err + } + key, err := section.NewBooleanKey(kname) + if err != nil { + return err + } + key.Comment = strings.TrimSpace(p.comment.String()) + p.comment.Reset() + continue + } + return err + } + + // Auto increment. + isAutoIncr := false + if kname == "-" { + isAutoIncr = true + kname = "#" + strconv.Itoa(p.count) + p.count++ + } + + value, err := p.readValue(line[offset:], f.options.IgnoreContinuation) + if err != nil { + return err + } + + key, err := section.NewKey(kname, value) + if err != nil { + return err + } + key.isAutoIncrement = isAutoIncr + key.Comment = strings.TrimSpace(p.comment.String()) + p.comment.Reset() + } + return nil +} diff --git a/vendor/github.com/go-ini/ini/section.go b/vendor/github.com/go-ini/ini/section.go new file mode 100644 index 000000000..c9fa27e9c --- /dev/null +++ b/vendor/github.com/go-ini/ini/section.go @@ -0,0 +1,234 @@ +// Copyright 2014 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +package ini + +import ( + "errors" + "fmt" + "strings" +) + +// Section represents a config section. +type Section struct { + f *File + Comment string + name string + keys map[string]*Key + keyList []string + keysHash map[string]string + + isRawSection bool + rawBody string +} + +func newSection(f *File, name string) *Section { + return &Section{ + f: f, + name: name, + keys: make(map[string]*Key), + keyList: make([]string, 0, 10), + keysHash: make(map[string]string), + } +} + +// Name returns name of Section. +func (s *Section) Name() string { + return s.name +} + +// Body returns rawBody of Section if the section was marked as unparseable. +// It still follows the other rules of the INI format surrounding leading/trailing whitespace. +func (s *Section) Body() string { + return strings.TrimSpace(s.rawBody) +} + +// NewKey creates a new key to given section. +func (s *Section) NewKey(name, val string) (*Key, error) { + if len(name) == 0 { + return nil, errors.New("error creating new key: empty key name") + } else if s.f.options.Insensitive { + name = strings.ToLower(name) + } + + if s.f.BlockMode { + s.f.lock.Lock() + defer s.f.lock.Unlock() + } + + if inSlice(name, s.keyList) { + if s.f.options.AllowShadows { + if err := s.keys[name].addShadow(val); err != nil { + return nil, err + } + } else { + s.keys[name].value = val + } + return s.keys[name], nil + } + + s.keyList = append(s.keyList, name) + s.keys[name] = newKey(s, name, val) + s.keysHash[name] = val + return s.keys[name], nil +} + +// NewBooleanKey creates a new boolean type key to given section. +func (s *Section) NewBooleanKey(name string) (*Key, error) { + key, err := s.NewKey(name, "true") + if err != nil { + return nil, err + } + + key.isBooleanType = true + return key, nil +} + +// GetKey returns key in section by given name. +func (s *Section) GetKey(name string) (*Key, error) { + // FIXME: change to section level lock? + if s.f.BlockMode { + s.f.lock.RLock() + } + if s.f.options.Insensitive { + name = strings.ToLower(name) + } + key := s.keys[name] + if s.f.BlockMode { + s.f.lock.RUnlock() + } + + if key == nil { + // Check if it is a child-section. + sname := s.name + for { + if i := strings.LastIndex(sname, "."); i > -1 { + sname = sname[:i] + sec, err := s.f.GetSection(sname) + if err != nil { + continue + } + return sec.GetKey(name) + } else { + break + } + } + return nil, fmt.Errorf("error when getting key of section '%s': key '%s' not exists", s.name, name) + } + return key, nil +} + +// HasKey returns true if section contains a key with given name. +func (s *Section) HasKey(name string) bool { + key, _ := s.GetKey(name) + return key != nil +} + +// Haskey is a backwards-compatible name for HasKey. +func (s *Section) Haskey(name string) bool { + return s.HasKey(name) +} + +// HasValue returns true if section contains given raw value. +func (s *Section) HasValue(value string) bool { + if s.f.BlockMode { + s.f.lock.RLock() + defer s.f.lock.RUnlock() + } + + for _, k := range s.keys { + if value == k.value { + return true + } + } + return false +} + +// Key assumes named Key exists in section and returns a zero-value when not. +func (s *Section) Key(name string) *Key { + key, err := s.GetKey(name) + if err != nil { + // It's OK here because the only possible error is empty key name, + // but if it's empty, this piece of code won't be executed. + key, _ = s.NewKey(name, "") + return key + } + return key +} + +// Keys returns list of keys of section. +func (s *Section) Keys() []*Key { + keys := make([]*Key, len(s.keyList)) + for i := range s.keyList { + keys[i] = s.Key(s.keyList[i]) + } + return keys +} + +// ParentKeys returns list of keys of parent section. +func (s *Section) ParentKeys() []*Key { + var parentKeys []*Key + sname := s.name + for { + if i := strings.LastIndex(sname, "."); i > -1 { + sname = sname[:i] + sec, err := s.f.GetSection(sname) + if err != nil { + continue + } + parentKeys = append(parentKeys, sec.Keys()...) + } else { + break + } + + } + return parentKeys +} + +// KeyStrings returns list of key names of section. +func (s *Section) KeyStrings() []string { + list := make([]string, len(s.keyList)) + copy(list, s.keyList) + return list +} + +// KeysHash returns keys hash consisting of names and values. +func (s *Section) KeysHash() map[string]string { + if s.f.BlockMode { + s.f.lock.RLock() + defer s.f.lock.RUnlock() + } + + hash := map[string]string{} + for key, value := range s.keysHash { + hash[key] = value + } + return hash +} + +// DeleteKey deletes a key from section. +func (s *Section) DeleteKey(name string) { + if s.f.BlockMode { + s.f.lock.Lock() + defer s.f.lock.Unlock() + } + + for i, k := range s.keyList { + if k == name { + s.keyList = append(s.keyList[:i], s.keyList[i+1:]...) + delete(s.keys, name) + return + } + } +} diff --git a/vendor/github.com/go-ini/ini/struct.go b/vendor/github.com/go-ini/ini/struct.go new file mode 100644 index 000000000..509c682fa --- /dev/null +++ b/vendor/github.com/go-ini/ini/struct.go @@ -0,0 +1,450 @@ +// Copyright 2014 Unknwon +// +// Licensed under the Apache License, Version 2.0 (the "License"): you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +// License for the specific language governing permissions and limitations +// under the License. + +package ini + +import ( + "bytes" + "errors" + "fmt" + "reflect" + "strings" + "time" + "unicode" +) + +// NameMapper represents a ini tag name mapper. +type NameMapper func(string) string + +// Built-in name getters. +var ( + // AllCapsUnderscore converts to format ALL_CAPS_UNDERSCORE. + AllCapsUnderscore NameMapper = func(raw string) string { + newstr := make([]rune, 0, len(raw)) + for i, chr := range raw { + if isUpper := 'A' <= chr && chr <= 'Z'; isUpper { + if i > 0 { + newstr = append(newstr, '_') + } + } + newstr = append(newstr, unicode.ToUpper(chr)) + } + return string(newstr) + } + // TitleUnderscore converts to format title_underscore. + TitleUnderscore NameMapper = func(raw string) string { + newstr := make([]rune, 0, len(raw)) + for i, chr := range raw { + if isUpper := 'A' <= chr && chr <= 'Z'; isUpper { + if i > 0 { + newstr = append(newstr, '_') + } + chr -= ('A' - 'a') + } + newstr = append(newstr, chr) + } + return string(newstr) + } +) + +func (s *Section) parseFieldName(raw, actual string) string { + if len(actual) > 0 { + return actual + } + if s.f.NameMapper != nil { + return s.f.NameMapper(raw) + } + return raw +} + +func parseDelim(actual string) string { + if len(actual) > 0 { + return actual + } + return "," +} + +var reflectTime = reflect.TypeOf(time.Now()).Kind() + +// setSliceWithProperType sets proper values to slice based on its type. +func setSliceWithProperType(key *Key, field reflect.Value, delim string, allowShadow bool) error { + var strs []string + if allowShadow { + strs = key.StringsWithShadows(delim) + } else { + strs = key.Strings(delim) + } + + numVals := len(strs) + if numVals == 0 { + return nil + } + + var vals interface{} + + sliceOf := field.Type().Elem().Kind() + switch sliceOf { + case reflect.String: + vals = strs + case reflect.Int: + vals, _ = key.parseInts(strs, true, false) + case reflect.Int64: + vals, _ = key.parseInt64s(strs, true, false) + case reflect.Uint: + vals = key.Uints(delim) + case reflect.Uint64: + vals = key.Uint64s(delim) + case reflect.Float64: + vals = key.Float64s(delim) + case reflectTime: + vals = key.Times(delim) + default: + return fmt.Errorf("unsupported type '[]%s'", sliceOf) + } + + slice := reflect.MakeSlice(field.Type(), numVals, numVals) + for i := 0; i < numVals; i++ { + switch sliceOf { + case reflect.String: + slice.Index(i).Set(reflect.ValueOf(vals.([]string)[i])) + case reflect.Int: + slice.Index(i).Set(reflect.ValueOf(vals.([]int)[i])) + case reflect.Int64: + slice.Index(i).Set(reflect.ValueOf(vals.([]int64)[i])) + case reflect.Uint: + slice.Index(i).Set(reflect.ValueOf(vals.([]uint)[i])) + case reflect.Uint64: + slice.Index(i).Set(reflect.ValueOf(vals.([]uint64)[i])) + case reflect.Float64: + slice.Index(i).Set(reflect.ValueOf(vals.([]float64)[i])) + case reflectTime: + slice.Index(i).Set(reflect.ValueOf(vals.([]time.Time)[i])) + } + } + field.Set(slice) + return nil +} + +// setWithProperType sets proper value to field based on its type, +// but it does not return error for failing parsing, +// because we want to use default value that is already assigned to strcut. +func setWithProperType(t reflect.Type, key *Key, field reflect.Value, delim string, allowShadow bool) error { + switch t.Kind() { + case reflect.String: + if len(key.String()) == 0 { + return nil + } + field.SetString(key.String()) + case reflect.Bool: + boolVal, err := key.Bool() + if err != nil { + return nil + } + field.SetBool(boolVal) + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + durationVal, err := key.Duration() + // Skip zero value + if err == nil && int(durationVal) > 0 { + field.Set(reflect.ValueOf(durationVal)) + return nil + } + + intVal, err := key.Int64() + if err != nil || intVal == 0 { + return nil + } + field.SetInt(intVal) + // byte is an alias for uint8, so supporting uint8 breaks support for byte + case reflect.Uint, reflect.Uint16, reflect.Uint32, reflect.Uint64: + durationVal, err := key.Duration() + // Skip zero value + if err == nil && int(durationVal) > 0 { + field.Set(reflect.ValueOf(durationVal)) + return nil + } + + uintVal, err := key.Uint64() + if err != nil { + return nil + } + field.SetUint(uintVal) + + case reflect.Float32, reflect.Float64: + floatVal, err := key.Float64() + if err != nil { + return nil + } + field.SetFloat(floatVal) + case reflectTime: + timeVal, err := key.Time() + if err != nil { + return nil + } + field.Set(reflect.ValueOf(timeVal)) + case reflect.Slice: + return setSliceWithProperType(key, field, delim, allowShadow) + default: + return fmt.Errorf("unsupported type '%s'", t) + } + return nil +} + +func parseTagOptions(tag string) (rawName string, omitEmpty bool, allowShadow bool) { + opts := strings.SplitN(tag, ",", 3) + rawName = opts[0] + if len(opts) > 1 { + omitEmpty = opts[1] == "omitempty" + } + if len(opts) > 2 { + allowShadow = opts[2] == "allowshadow" + } + return rawName, omitEmpty, allowShadow +} + +func (s *Section) mapTo(val reflect.Value) error { + if val.Kind() == reflect.Ptr { + val = val.Elem() + } + typ := val.Type() + + for i := 0; i < typ.NumField(); i++ { + field := val.Field(i) + tpField := typ.Field(i) + + tag := tpField.Tag.Get("ini") + if tag == "-" { + continue + } + + rawName, _, allowShadow := parseTagOptions(tag) + fieldName := s.parseFieldName(tpField.Name, rawName) + if len(fieldName) == 0 || !field.CanSet() { + continue + } + + isAnonymous := tpField.Type.Kind() == reflect.Ptr && tpField.Anonymous + isStruct := tpField.Type.Kind() == reflect.Struct + if isAnonymous { + field.Set(reflect.New(tpField.Type.Elem())) + } + + if isAnonymous || isStruct { + if sec, err := s.f.GetSection(fieldName); err == nil { + if err = sec.mapTo(field); err != nil { + return fmt.Errorf("error mapping field(%s): %v", fieldName, err) + } + continue + } + } + + if key, err := s.GetKey(fieldName); err == nil { + delim := parseDelim(tpField.Tag.Get("delim")) + if err = setWithProperType(tpField.Type, key, field, delim, allowShadow); err != nil { + return fmt.Errorf("error mapping field(%s): %v", fieldName, err) + } + } + } + return nil +} + +// MapTo maps section to given struct. +func (s *Section) MapTo(v interface{}) error { + typ := reflect.TypeOf(v) + val := reflect.ValueOf(v) + if typ.Kind() == reflect.Ptr { + typ = typ.Elem() + val = val.Elem() + } else { + return errors.New("cannot map to non-pointer struct") + } + + return s.mapTo(val) +} + +// MapTo maps file to given struct. +func (f *File) MapTo(v interface{}) error { + return f.Section("").MapTo(v) +} + +// MapTo maps data sources to given struct with name mapper. +func MapToWithMapper(v interface{}, mapper NameMapper, source interface{}, others ...interface{}) error { + cfg, err := Load(source, others...) + if err != nil { + return err + } + cfg.NameMapper = mapper + return cfg.MapTo(v) +} + +// MapTo maps data sources to given struct. +func MapTo(v, source interface{}, others ...interface{}) error { + return MapToWithMapper(v, nil, source, others...) +} + +// reflectSliceWithProperType does the opposite thing as setSliceWithProperType. +func reflectSliceWithProperType(key *Key, field reflect.Value, delim string) error { + slice := field.Slice(0, field.Len()) + if field.Len() == 0 { + return nil + } + + var buf bytes.Buffer + sliceOf := field.Type().Elem().Kind() + for i := 0; i < field.Len(); i++ { + switch sliceOf { + case reflect.String: + buf.WriteString(slice.Index(i).String()) + case reflect.Int, reflect.Int64: + buf.WriteString(fmt.Sprint(slice.Index(i).Int())) + case reflect.Uint, reflect.Uint64: + buf.WriteString(fmt.Sprint(slice.Index(i).Uint())) + case reflect.Float64: + buf.WriteString(fmt.Sprint(slice.Index(i).Float())) + case reflectTime: + buf.WriteString(slice.Index(i).Interface().(time.Time).Format(time.RFC3339)) + default: + return fmt.Errorf("unsupported type '[]%s'", sliceOf) + } + buf.WriteString(delim) + } + key.SetValue(buf.String()[:buf.Len()-1]) + return nil +} + +// reflectWithProperType does the opposite thing as setWithProperType. +func reflectWithProperType(t reflect.Type, key *Key, field reflect.Value, delim string) error { + switch t.Kind() { + case reflect.String: + key.SetValue(field.String()) + case reflect.Bool: + key.SetValue(fmt.Sprint(field.Bool())) + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + key.SetValue(fmt.Sprint(field.Int())) + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + key.SetValue(fmt.Sprint(field.Uint())) + case reflect.Float32, reflect.Float64: + key.SetValue(fmt.Sprint(field.Float())) + case reflectTime: + key.SetValue(fmt.Sprint(field.Interface().(time.Time).Format(time.RFC3339))) + case reflect.Slice: + return reflectSliceWithProperType(key, field, delim) + default: + return fmt.Errorf("unsupported type '%s'", t) + } + return nil +} + +// CR: copied from encoding/json/encode.go with modifications of time.Time support. +// TODO: add more test coverage. +func isEmptyValue(v reflect.Value) bool { + switch v.Kind() { + case reflect.Array, reflect.Map, reflect.Slice, reflect.String: + return v.Len() == 0 + case reflect.Bool: + return !v.Bool() + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + return v.Int() == 0 + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: + return v.Uint() == 0 + case reflect.Float32, reflect.Float64: + return v.Float() == 0 + case reflectTime: + return v.Interface().(time.Time).IsZero() + case reflect.Interface, reflect.Ptr: + return v.IsNil() + } + return false +} + +func (s *Section) reflectFrom(val reflect.Value) error { + if val.Kind() == reflect.Ptr { + val = val.Elem() + } + typ := val.Type() + + for i := 0; i < typ.NumField(); i++ { + field := val.Field(i) + tpField := typ.Field(i) + + tag := tpField.Tag.Get("ini") + if tag == "-" { + continue + } + + opts := strings.SplitN(tag, ",", 2) + if len(opts) == 2 && opts[1] == "omitempty" && isEmptyValue(field) { + continue + } + + fieldName := s.parseFieldName(tpField.Name, opts[0]) + if len(fieldName) == 0 || !field.CanSet() { + continue + } + + if (tpField.Type.Kind() == reflect.Ptr && tpField.Anonymous) || + (tpField.Type.Kind() == reflect.Struct && tpField.Type.Name() != "Time") { + // Note: The only error here is section doesn't exist. + sec, err := s.f.GetSection(fieldName) + if err != nil { + // Note: fieldName can never be empty here, ignore error. + sec, _ = s.f.NewSection(fieldName) + } + if err = sec.reflectFrom(field); err != nil { + return fmt.Errorf("error reflecting field (%s): %v", fieldName, err) + } + continue + } + + // Note: Same reason as secion. + key, err := s.GetKey(fieldName) + if err != nil { + key, _ = s.NewKey(fieldName, "") + } + if err = reflectWithProperType(tpField.Type, key, field, parseDelim(tpField.Tag.Get("delim"))); err != nil { + return fmt.Errorf("error reflecting field (%s): %v", fieldName, err) + } + + } + return nil +} + +// ReflectFrom reflects secion from given struct. +func (s *Section) ReflectFrom(v interface{}) error { + typ := reflect.TypeOf(v) + val := reflect.ValueOf(v) + if typ.Kind() == reflect.Ptr { + typ = typ.Elem() + val = val.Elem() + } else { + return errors.New("cannot reflect from non-pointer struct") + } + + return s.reflectFrom(val) +} + +// ReflectFrom reflects file from given struct. +func (f *File) ReflectFrom(v interface{}) error { + return f.Section("").ReflectFrom(v) +} + +// ReflectFrom reflects data sources from given struct with name mapper. +func ReflectFromWithMapper(cfg *File, v interface{}, mapper NameMapper) error { + cfg.NameMapper = mapper + return cfg.ReflectFrom(v) +} + +// ReflectFrom reflects data sources from given struct. +func ReflectFrom(cfg *File, v interface{}) error { + return ReflectFromWithMapper(cfg, v, nil) +} diff --git a/vendor/github.com/hashicorp/go-raftchunking/api.go b/vendor/github.com/hashicorp/go-raftchunking/api.go index d6475e378..96ba6f8d5 100644 --- a/vendor/github.com/hashicorp/go-raftchunking/api.go +++ b/vendor/github.com/hashicorp/go-raftchunking/api.go @@ -14,12 +14,6 @@ import ( "github.com/hashicorp/raft" ) -var ( - // ChunkSize is the threshold used for breaking a large value into chunks. - // Defaults to the suggested max data size for the raft library. - ChunkSize = raft.SuggestedMaxDataSize -) - // errorFuture is used to return a static error. type errorFuture struct { err error @@ -78,15 +72,15 @@ func (m multiFuture) Response() interface{} { type ApplyFunc func(raft.Log, time.Duration) raft.ApplyFuture -// ChunkingApply takes in a byte slice and chunks into ChunkSize (or less if -// EOF) chunks, calling Apply on each. It requires a corresponding wrapper -// around the FSM to handle reconstructing on the other end. Timeout will be the -// timeout for each individual operation, not total. The return value is a -// future whose Error() will return only when all underlying Apply futures have -// had Error() return. Note that any error indicates that the entire operation -// will not be applied, assuming the correct FSM wrapper is used. If extensions -// is passed in, it will be set as the Extensions value on the Apply once all -// chunks are received. +// ChunkingApply takes in a byte slice and chunks into +// raft.SuggestedMaxDataSize (or less if EOF) chunks, calling Apply on each. It +// requires a corresponding wrapper around the FSM to handle reconstructing on +// the other end. Timeout will be the timeout for each individual operation, +// not total. The return value is a future whose Error() will return only when +// all underlying Apply futures have had Error() return. Note that any error +// indicates that the entire operation will not be applied, assuming the +// correct FSM wrapper is used. If extensions is passed in, it will be set as +// the Extensions value on the Apply once all chunks are received. func ChunkingApply(cmd, extensions []byte, timeout time.Duration, applyFunc ApplyFunc) raft.ApplyFuture { // Generate a random op num via 64 random bits. These only have to be // unique across _in flight_ chunk operations until a Term changes so @@ -117,8 +111,8 @@ func ChunkingApply(cmd, extensions []byte, timeout time.Duration, applyFunc Appl break } - if remain > ChunkSize { - remain = ChunkSize + if remain > raft.SuggestedMaxDataSize { + remain = raft.SuggestedMaxDataSize } b := make([]byte, remain) diff --git a/vendor/github.com/hashicorp/go-raftchunking/fsm.go b/vendor/github.com/hashicorp/go-raftchunking/fsm.go index 53e0e00ef..c3ed8f512 100644 --- a/vendor/github.com/hashicorp/go-raftchunking/fsm.go +++ b/vendor/github.com/hashicorp/go-raftchunking/fsm.go @@ -119,7 +119,7 @@ func (c *ChunkingFSM) Apply(l *raft.Log) interface{} { Extensions: ci.NextExtensions, } - return ChunkingSuccess{Response: c.underlying.Apply(logToApply)} + return ChunkingSuccess{Response: c.Apply(logToApply)} } func (c *ChunkingFSM) Snapshot() (raft.FSMSnapshot, error) { diff --git a/vendor/github.com/jmespath/go-jmespath/.gitignore b/vendor/github.com/jmespath/go-jmespath/.gitignore index 5091fb073..531fcc11c 100644 --- a/vendor/github.com/jmespath/go-jmespath/.gitignore +++ b/vendor/github.com/jmespath/go-jmespath/.gitignore @@ -1,4 +1,4 @@ -/jpgo +jpgo jmespath-fuzz.zip cpu.out go-jmespath.test diff --git a/vendor/github.com/jmespath/go-jmespath/api.go b/vendor/github.com/jmespath/go-jmespath/api.go index 8e26ffeec..9cfa988bc 100644 --- a/vendor/github.com/jmespath/go-jmespath/api.go +++ b/vendor/github.com/jmespath/go-jmespath/api.go @@ -2,7 +2,7 @@ package jmespath import "strconv" -// JMESPath is the epresentation of a compiled JMES path query. A JMESPath is +// JmesPath is the epresentation of a compiled JMES path query. A JmesPath is // safe for concurrent use by multiple goroutines. type JMESPath struct { ast ASTNode diff --git a/vendor/modules.txt b/vendor/modules.txt index 9fdb7cfc2..683391e51 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -46,42 +46,36 @@ github.com/armon/go-metrics/prometheus github.com/armon/go-radix # github.com/asaskevich/govalidator v0.0.0-20180319081651-7d2e70ef918f github.com/asaskevich/govalidator -# github.com/aws/aws-sdk-go v1.21.1 +# github.com/aws/aws-sdk-go v1.15.24 github.com/aws/aws-sdk-go/aws -github.com/aws/aws-sdk-go/aws/awserr github.com/aws/aws-sdk-go/aws/credentials +github.com/aws/aws-sdk-go/aws/defaults +github.com/aws/aws-sdk-go/aws/ec2metadata github.com/aws/aws-sdk-go/aws/session -github.com/aws/aws-sdk-go/service/acmpca +github.com/aws/aws-sdk-go/service/ec2 +github.com/aws/aws-sdk-go/aws/awserr github.com/aws/aws-sdk-go/aws/endpoints github.com/aws/aws-sdk-go/internal/sdkio -github.com/aws/aws-sdk-go/internal/ini github.com/aws/aws-sdk-go/internal/shareddefaults -github.com/aws/aws-sdk-go/aws/client github.com/aws/aws-sdk-go/aws/corehandlers -github.com/aws/aws-sdk-go/aws/credentials/processcreds -github.com/aws/aws-sdk-go/aws/credentials/stscreds -github.com/aws/aws-sdk-go/aws/csm -github.com/aws/aws-sdk-go/aws/defaults -github.com/aws/aws-sdk-go/aws/request -github.com/aws/aws-sdk-go/aws/awsutil -github.com/aws/aws-sdk-go/aws/client/metadata -github.com/aws/aws-sdk-go/aws/signer/v4 -github.com/aws/aws-sdk-go/private/protocol -github.com/aws/aws-sdk-go/private/protocol/jsonrpc -github.com/aws/aws-sdk-go/aws/ec2metadata -github.com/aws/aws-sdk-go/service/ec2 -github.com/aws/aws-sdk-go/internal/sdkrand -github.com/aws/aws-sdk-go/service/sts -github.com/aws/aws-sdk-go/service/sts/stsiface github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds github.com/aws/aws-sdk-go/aws/credentials/endpointcreds -github.com/aws/aws-sdk-go/private/protocol/rest -github.com/aws/aws-sdk-go/private/protocol/json/jsonutil +github.com/aws/aws-sdk-go/aws/request +github.com/aws/aws-sdk-go/aws/client +github.com/aws/aws-sdk-go/aws/client/metadata github.com/aws/aws-sdk-go/internal/sdkuri +github.com/aws/aws-sdk-go/aws/credentials/stscreds +github.com/aws/aws-sdk-go/aws/csm +github.com/aws/aws-sdk-go/aws/awsutil +github.com/aws/aws-sdk-go/aws/signer/v4 +github.com/aws/aws-sdk-go/internal/sdkrand +github.com/aws/aws-sdk-go/private/protocol github.com/aws/aws-sdk-go/private/protocol/ec2query -github.com/aws/aws-sdk-go/private/protocol/query +github.com/aws/aws-sdk-go/service/sts +github.com/aws/aws-sdk-go/private/protocol/rest github.com/aws/aws-sdk-go/private/protocol/query/queryutil github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil +github.com/aws/aws-sdk-go/private/protocol/query # github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973 github.com/beorn7/perks/quantile # github.com/bgentry/speakeasy v0.1.0 @@ -139,6 +133,8 @@ github.com/fatih/color github.com/fatih/structs # github.com/ghodss/yaml v1.0.0 github.com/ghodss/yaml +# github.com/go-ini/ini v1.25.4 +github.com/go-ini/ini # github.com/go-ole/go-ole v1.2.1 github.com/go-ole/go-ole github.com/go-ole/go-ole/oleutil @@ -153,9 +149,9 @@ github.com/gocql/gocql/internal/streams github.com/gogo/googleapis/google/rpc github.com/gogo/googleapis/google/api # github.com/gogo/protobuf v1.2.1 -github.com/gogo/protobuf/types github.com/gogo/protobuf/jsonpb github.com/gogo/protobuf/proto +github.com/gogo/protobuf/types github.com/gogo/protobuf/sortkeys github.com/gogo/protobuf/gogoproto github.com/gogo/protobuf/protoc-gen-gogo/descriptor @@ -231,7 +227,7 @@ github.com/hashicorp/go-msgpack/codec github.com/hashicorp/go-multierror # github.com/hashicorp/go-plugin v0.0.0-20180331002553-e8d22c780116 github.com/hashicorp/go-plugin -# github.com/hashicorp/go-raftchunking v0.6.2 +# github.com/hashicorp/go-raftchunking v0.6.1 github.com/hashicorp/go-raftchunking github.com/hashicorp/go-raftchunking/types # github.com/hashicorp/go-retryablehttp v0.5.3 @@ -337,7 +333,7 @@ github.com/hashicorp/yamux github.com/imdario/mergo # github.com/jefferai/jsonx v0.0.0-20160721235117-9cc31c3135ee github.com/jefferai/jsonx -# github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af +# github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8 github.com/jmespath/go-jmespath # github.com/joyent/triton-go v0.0.0-20180628001255-830d2b111e62 github.com/joyent/triton-go