Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
awssdkgo Release v1.21.0 f062d23 Jul 19, 2019
5 contributors

Users who have contributed to this file

@lsegal @jasdel @xibz @bpot @euank
14477 lines (12595 sloc) 529 KB
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
package elasticache
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/query"
)
const opAddTagsToResource = "AddTagsToResource"
// AddTagsToResourceRequest generates a "aws/request.Request" representing the
// client's request for the AddTagsToResource 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 AddTagsToResource for more information on using the AddTagsToResource
// 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 AddTagsToResourceRequest method.
// req, resp := client.AddTagsToResourceRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/AddTagsToResource
func (c *ElastiCache) AddTagsToResourceRequest(input *AddTagsToResourceInput) (req *request.Request, output *TagListMessage) {
op := &request.Operation{
Name: opAddTagsToResource,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AddTagsToResourceInput{}
}
output = &TagListMessage{}
req = c.newRequest(op, input, output)
return
}
// AddTagsToResource API operation for Amazon ElastiCache.
//
// Adds up to 50 cost allocation tags to the named resource. A cost allocation
// tag is a key-value pair where the key and value are case-sensitive. You can
// use cost allocation tags to categorize and track your AWS costs.
//
// When you apply tags to your ElastiCache resources, AWS generates a cost allocation
// report as a comma-separated value (CSV) file with your usage and costs aggregated
// by your tags. You can apply tags that represent business categories (such
// as cost centers, application names, or owners) to organize your costs across
// multiple services. For more information, see Using Cost Allocation Tags in
// Amazon ElastiCache (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/Tagging.html)
// in the ElastiCache 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 ElastiCache's
// API operation AddTagsToResource for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheClusterNotFoundFault "CacheClusterNotFound"
// The requested cluster ID does not refer to an existing cluster.
//
// * ErrCodeSnapshotNotFoundFault "SnapshotNotFoundFault"
// The requested snapshot name does not refer to an existing snapshot.
//
// * ErrCodeTagQuotaPerResourceExceeded "TagQuotaPerResourceExceeded"
// The request cannot be processed because it would cause the resource to have
// more than the allowed number of tags. The maximum number of tags permitted
// on a resource is 50.
//
// * ErrCodeInvalidARNFault "InvalidARN"
// The requested Amazon Resource Name (ARN) does not refer to an existing resource.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/AddTagsToResource
func (c *ElastiCache) AddTagsToResource(input *AddTagsToResourceInput) (*TagListMessage, error) {
req, out := c.AddTagsToResourceRequest(input)
return out, req.Send()
}
// AddTagsToResourceWithContext is the same as AddTagsToResource with the addition of
// the ability to pass a context and additional request options.
//
// See AddTagsToResource 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 *ElastiCache) AddTagsToResourceWithContext(ctx aws.Context, input *AddTagsToResourceInput, opts ...request.Option) (*TagListMessage, error) {
req, out := c.AddTagsToResourceRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opAuthorizeCacheSecurityGroupIngress = "AuthorizeCacheSecurityGroupIngress"
// AuthorizeCacheSecurityGroupIngressRequest generates a "aws/request.Request" representing the
// client's request for the AuthorizeCacheSecurityGroupIngress 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 AuthorizeCacheSecurityGroupIngress for more information on using the AuthorizeCacheSecurityGroupIngress
// 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 AuthorizeCacheSecurityGroupIngressRequest method.
// req, resp := client.AuthorizeCacheSecurityGroupIngressRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/AuthorizeCacheSecurityGroupIngress
func (c *ElastiCache) AuthorizeCacheSecurityGroupIngressRequest(input *AuthorizeCacheSecurityGroupIngressInput) (req *request.Request, output *AuthorizeCacheSecurityGroupIngressOutput) {
op := &request.Operation{
Name: opAuthorizeCacheSecurityGroupIngress,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AuthorizeCacheSecurityGroupIngressInput{}
}
output = &AuthorizeCacheSecurityGroupIngressOutput{}
req = c.newRequest(op, input, output)
return
}
// AuthorizeCacheSecurityGroupIngress API operation for Amazon ElastiCache.
//
// Allows network ingress to a cache security group. Applications using ElastiCache
// must be running on Amazon EC2, and Amazon EC2 security groups are used as
// the authorization mechanism.
//
// You cannot authorize ingress from an Amazon EC2 security group in one region
// to an ElastiCache cluster in another 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
// the error.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation AuthorizeCacheSecurityGroupIngress for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSecurityGroupNotFoundFault "CacheSecurityGroupNotFound"
// The requested cache security group name does not refer to an existing cache
// security group.
//
// * ErrCodeInvalidCacheSecurityGroupStateFault "InvalidCacheSecurityGroupState"
// The current state of the cache security group does not allow deletion.
//
// * ErrCodeAuthorizationAlreadyExistsFault "AuthorizationAlreadyExists"
// The specified Amazon EC2 security group is already authorized for the specified
// cache security group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/AuthorizeCacheSecurityGroupIngress
func (c *ElastiCache) AuthorizeCacheSecurityGroupIngress(input *AuthorizeCacheSecurityGroupIngressInput) (*AuthorizeCacheSecurityGroupIngressOutput, error) {
req, out := c.AuthorizeCacheSecurityGroupIngressRequest(input)
return out, req.Send()
}
// AuthorizeCacheSecurityGroupIngressWithContext is the same as AuthorizeCacheSecurityGroupIngress with the addition of
// the ability to pass a context and additional request options.
//
// See AuthorizeCacheSecurityGroupIngress 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 *ElastiCache) AuthorizeCacheSecurityGroupIngressWithContext(ctx aws.Context, input *AuthorizeCacheSecurityGroupIngressInput, opts ...request.Option) (*AuthorizeCacheSecurityGroupIngressOutput, error) {
req, out := c.AuthorizeCacheSecurityGroupIngressRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opBatchApplyUpdateAction = "BatchApplyUpdateAction"
// BatchApplyUpdateActionRequest generates a "aws/request.Request" representing the
// client's request for the BatchApplyUpdateAction 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 BatchApplyUpdateAction for more information on using the BatchApplyUpdateAction
// 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 BatchApplyUpdateActionRequest method.
// req, resp := client.BatchApplyUpdateActionRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/BatchApplyUpdateAction
func (c *ElastiCache) BatchApplyUpdateActionRequest(input *BatchApplyUpdateActionInput) (req *request.Request, output *BatchApplyUpdateActionOutput) {
op := &request.Operation{
Name: opBatchApplyUpdateAction,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &BatchApplyUpdateActionInput{}
}
output = &BatchApplyUpdateActionOutput{}
req = c.newRequest(op, input, output)
return
}
// BatchApplyUpdateAction API operation for Amazon ElastiCache.
//
// Apply the service update. For more information on service updates and applying
// them, see Applying Service Updates (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/applying-updates.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.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation BatchApplyUpdateAction for usage and error information.
//
// Returned Error Codes:
// * ErrCodeServiceUpdateNotFoundFault "ServiceUpdateNotFoundFault"
// The service update doesn't exist
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/BatchApplyUpdateAction
func (c *ElastiCache) BatchApplyUpdateAction(input *BatchApplyUpdateActionInput) (*BatchApplyUpdateActionOutput, error) {
req, out := c.BatchApplyUpdateActionRequest(input)
return out, req.Send()
}
// BatchApplyUpdateActionWithContext is the same as BatchApplyUpdateAction with the addition of
// the ability to pass a context and additional request options.
//
// See BatchApplyUpdateAction 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 *ElastiCache) BatchApplyUpdateActionWithContext(ctx aws.Context, input *BatchApplyUpdateActionInput, opts ...request.Option) (*BatchApplyUpdateActionOutput, error) {
req, out := c.BatchApplyUpdateActionRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opBatchStopUpdateAction = "BatchStopUpdateAction"
// BatchStopUpdateActionRequest generates a "aws/request.Request" representing the
// client's request for the BatchStopUpdateAction 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 BatchStopUpdateAction for more information on using the BatchStopUpdateAction
// 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 BatchStopUpdateActionRequest method.
// req, resp := client.BatchStopUpdateActionRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/BatchStopUpdateAction
func (c *ElastiCache) BatchStopUpdateActionRequest(input *BatchStopUpdateActionInput) (req *request.Request, output *BatchStopUpdateActionOutput) {
op := &request.Operation{
Name: opBatchStopUpdateAction,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &BatchStopUpdateActionInput{}
}
output = &BatchStopUpdateActionOutput{}
req = c.newRequest(op, input, output)
return
}
// BatchStopUpdateAction API operation for Amazon ElastiCache.
//
// Stop the service update. For more information on service updates and stopping
// them, see Stopping Service Updates (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/stopping-self-service-updates.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.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation BatchStopUpdateAction for usage and error information.
//
// Returned Error Codes:
// * ErrCodeServiceUpdateNotFoundFault "ServiceUpdateNotFoundFault"
// The service update doesn't exist
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/BatchStopUpdateAction
func (c *ElastiCache) BatchStopUpdateAction(input *BatchStopUpdateActionInput) (*BatchStopUpdateActionOutput, error) {
req, out := c.BatchStopUpdateActionRequest(input)
return out, req.Send()
}
// BatchStopUpdateActionWithContext is the same as BatchStopUpdateAction with the addition of
// the ability to pass a context and additional request options.
//
// See BatchStopUpdateAction 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 *ElastiCache) BatchStopUpdateActionWithContext(ctx aws.Context, input *BatchStopUpdateActionInput, opts ...request.Option) (*BatchStopUpdateActionOutput, error) {
req, out := c.BatchStopUpdateActionRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
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.
//
// Use "Send" method on 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 CopySnapshot for more information on using the CopySnapshot
// 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 CopySnapshotRequest method.
// req, resp := client.CopySnapshotRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CopySnapshot
func (c *ElastiCache) CopySnapshotRequest(input *CopySnapshotInput) (req *request.Request, output *CopySnapshotOutput) {
op := &request.Operation{
Name: opCopySnapshot,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CopySnapshotInput{}
}
output = &CopySnapshotOutput{}
req = c.newRequest(op, input, output)
return
}
// CopySnapshot API operation for Amazon ElastiCache.
//
// Makes a copy of an existing snapshot.
//
// This operation is valid for Redis only.
//
// Users or groups that have permissions to use the CopySnapshot operation can
// create their own Amazon S3 buckets and copy snapshots to it. To control access
// to your snapshots, use an IAM policy to control who has the ability to use
// the CopySnapshot operation. For more information about using IAM to control
// the use of ElastiCache operations, see Exporting Snapshots (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html)
// and Authentication & Access Control (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/IAM.html).
//
// You could receive the following error messages.
//
// Error Messages
//
// * Error Message: The S3 bucket %s is outside of the region. Solution:
// Create an Amazon S3 bucket in the same region as your snapshot. For more
// information, see Step 1: Create an Amazon S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-create-s3-bucket)
// in the ElastiCache User Guide.
//
// * Error Message: The S3 bucket %s does not exist. Solution: Create an
// Amazon S3 bucket in the same region as your snapshot. For more information,
// see Step 1: Create an Amazon S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-create-s3-bucket)
// in the ElastiCache User Guide.
//
// * Error Message: The S3 bucket %s is not owned by the authenticated user.
// Solution: Create an Amazon S3 bucket in the same region as your snapshot.
// For more information, see Step 1: Create an Amazon S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-create-s3-bucket)
// in the ElastiCache User Guide.
//
// * Error Message: The authenticated user does not have sufficient permissions
// to perform the desired activity. Solution: Contact your system administrator
// to get the needed permissions.
//
// * Error Message: The S3 bucket %s already contains an object with key
// %s. Solution: Give the TargetSnapshotName a new and unique value. If exporting
// a snapshot, you could alternatively create a new Amazon S3 bucket and
// use this same value for TargetSnapshotName.
//
// * Error Message: ElastiCache has not been granted READ permissions %s
// on the S3 Bucket. Solution: Add List and Read permissions on the bucket.
// For more information, see Step 2: Grant ElastiCache Access to Your Amazon
// S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-grant-access)
// in the ElastiCache User Guide.
//
// * Error Message: ElastiCache has not been granted WRITE permissions %s
// on the S3 Bucket. Solution: Add Upload/Delete permissions on the bucket.
// For more information, see Step 2: Grant ElastiCache Access to Your Amazon
// S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-grant-access)
// in the ElastiCache User Guide.
//
// * Error Message: ElastiCache has not been granted READ_ACP permissions
// %s on the S3 Bucket. Solution: Add View Permissions on the bucket. For
// more information, see Step 2: Grant ElastiCache Access to Your Amazon
// S3 Bucket (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-exporting.html#backups-exporting-grant-access)
// in the ElastiCache 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 ElastiCache's
// API operation CopySnapshot for usage and error information.
//
// Returned Error Codes:
// * ErrCodeSnapshotAlreadyExistsFault "SnapshotAlreadyExistsFault"
// You already have a snapshot with the given name.
//
// * ErrCodeSnapshotNotFoundFault "SnapshotNotFoundFault"
// The requested snapshot name does not refer to an existing snapshot.
//
// * ErrCodeSnapshotQuotaExceededFault "SnapshotQuotaExceededFault"
// The request cannot be processed because it would exceed the maximum number
// of snapshots.
//
// * ErrCodeInvalidSnapshotStateFault "InvalidSnapshotState"
// The current state of the snapshot does not allow the requested operation
// to occur.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CopySnapshot
func (c *ElastiCache) CopySnapshot(input *CopySnapshotInput) (*CopySnapshotOutput, error) {
req, out := c.CopySnapshotRequest(input)
return out, req.Send()
}
// CopySnapshotWithContext is the same as CopySnapshot with the addition of
// the ability to pass a context and additional request options.
//
// See CopySnapshot 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 *ElastiCache) CopySnapshotWithContext(ctx aws.Context, input *CopySnapshotInput, opts ...request.Option) (*CopySnapshotOutput, error) {
req, out := c.CopySnapshotRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opCreateCacheCluster = "CreateCacheCluster"
// CreateCacheClusterRequest generates a "aws/request.Request" representing the
// client's request for the CreateCacheCluster 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 CreateCacheCluster for more information on using the CreateCacheCluster
// 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 CreateCacheClusterRequest method.
// req, resp := client.CreateCacheClusterRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheCluster
func (c *ElastiCache) CreateCacheClusterRequest(input *CreateCacheClusterInput) (req *request.Request, output *CreateCacheClusterOutput) {
op := &request.Operation{
Name: opCreateCacheCluster,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateCacheClusterInput{}
}
output = &CreateCacheClusterOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateCacheCluster API operation for Amazon ElastiCache.
//
// Creates a cluster. All nodes in the cluster run the same protocol-compliant
// cache engine software, either Memcached or Redis.
//
// This operation is not supported for Redis (cluster mode enabled) clusters.
//
// 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 ElastiCache's
// API operation CreateCacheCluster for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReplicationGroupNotFoundFault "ReplicationGroupNotFoundFault"
// The specified replication group does not exist.
//
// * ErrCodeInvalidReplicationGroupStateFault "InvalidReplicationGroupState"
// The requested replication group is not in the available state.
//
// * ErrCodeCacheClusterAlreadyExistsFault "CacheClusterAlreadyExists"
// You already have a cluster with the given identifier.
//
// * ErrCodeInsufficientCacheClusterCapacityFault "InsufficientCacheClusterCapacity"
// The requested cache node type is not available in the specified Availability
// Zone. For more information, see InsufficientCacheClusterCapacity (http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ErrorMessages.html#ErrorMessages.INSUFFICIENT_CACHE_CLUSTER_CAPACITY)
// in the ElastiCache User Guide.
//
// * ErrCodeCacheSecurityGroupNotFoundFault "CacheSecurityGroupNotFound"
// The requested cache security group name does not refer to an existing cache
// security group.
//
// * ErrCodeCacheSubnetGroupNotFoundFault "CacheSubnetGroupNotFoundFault"
// The requested cache subnet group name does not refer to an existing cache
// subnet group.
//
// * ErrCodeClusterQuotaForCustomerExceededFault "ClusterQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of clusters per customer.
//
// * ErrCodeNodeQuotaForClusterExceededFault "NodeQuotaForClusterExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache nodes in a single cluster.
//
// * ErrCodeNodeQuotaForCustomerExceededFault "NodeQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache nodes per customer.
//
// * ErrCodeCacheParameterGroupNotFoundFault "CacheParameterGroupNotFound"
// The requested cache parameter group name does not refer to an existing cache
// parameter group.
//
// * ErrCodeInvalidVPCNetworkStateFault "InvalidVPCNetworkStateFault"
// The VPC network is in an invalid state.
//
// * ErrCodeTagQuotaPerResourceExceeded "TagQuotaPerResourceExceeded"
// The request cannot be processed because it would cause the resource to have
// more than the allowed number of tags. The maximum number of tags permitted
// on a resource is 50.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheCluster
func (c *ElastiCache) CreateCacheCluster(input *CreateCacheClusterInput) (*CreateCacheClusterOutput, error) {
req, out := c.CreateCacheClusterRequest(input)
return out, req.Send()
}
// CreateCacheClusterWithContext is the same as CreateCacheCluster with the addition of
// the ability to pass a context and additional request options.
//
// See CreateCacheCluster 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 *ElastiCache) CreateCacheClusterWithContext(ctx aws.Context, input *CreateCacheClusterInput, opts ...request.Option) (*CreateCacheClusterOutput, error) {
req, out := c.CreateCacheClusterRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opCreateCacheParameterGroup = "CreateCacheParameterGroup"
// CreateCacheParameterGroupRequest generates a "aws/request.Request" representing the
// client's request for the CreateCacheParameterGroup 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 CreateCacheParameterGroup for more information on using the CreateCacheParameterGroup
// 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 CreateCacheParameterGroupRequest method.
// req, resp := client.CreateCacheParameterGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheParameterGroup
func (c *ElastiCache) CreateCacheParameterGroupRequest(input *CreateCacheParameterGroupInput) (req *request.Request, output *CreateCacheParameterGroupOutput) {
op := &request.Operation{
Name: opCreateCacheParameterGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateCacheParameterGroupInput{}
}
output = &CreateCacheParameterGroupOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateCacheParameterGroup API operation for Amazon ElastiCache.
//
// Creates a new Amazon ElastiCache cache parameter group. An ElastiCache cache
// parameter group is a collection of parameters and their values that are applied
// to all of the nodes in any cluster or replication group using the CacheParameterGroup.
//
// A newly created CacheParameterGroup is an exact duplicate of the default
// parameter group for the CacheParameterGroupFamily. To customize the newly
// created CacheParameterGroup you can change the values of specific parameters.
// For more information, see:
//
// * ModifyCacheParameterGroup (https://docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_ModifyCacheParameterGroup.html)
// in the ElastiCache API Reference.
//
// * Parameters and Parameter Groups (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ParameterGroups.html)
// in the ElastiCache 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 ElastiCache's
// API operation CreateCacheParameterGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheParameterGroupQuotaExceededFault "CacheParameterGroupQuotaExceeded"
// The request cannot be processed because it would exceed the maximum number
// of cache security groups.
//
// * ErrCodeCacheParameterGroupAlreadyExistsFault "CacheParameterGroupAlreadyExists"
// A cache parameter group with the requested name already exists.
//
// * ErrCodeInvalidCacheParameterGroupStateFault "InvalidCacheParameterGroupState"
// The current state of the cache parameter group does not allow the requested
// operation to occur.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheParameterGroup
func (c *ElastiCache) CreateCacheParameterGroup(input *CreateCacheParameterGroupInput) (*CreateCacheParameterGroupOutput, error) {
req, out := c.CreateCacheParameterGroupRequest(input)
return out, req.Send()
}
// CreateCacheParameterGroupWithContext is the same as CreateCacheParameterGroup with the addition of
// the ability to pass a context and additional request options.
//
// See CreateCacheParameterGroup 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 *ElastiCache) CreateCacheParameterGroupWithContext(ctx aws.Context, input *CreateCacheParameterGroupInput, opts ...request.Option) (*CreateCacheParameterGroupOutput, error) {
req, out := c.CreateCacheParameterGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opCreateCacheSecurityGroup = "CreateCacheSecurityGroup"
// CreateCacheSecurityGroupRequest generates a "aws/request.Request" representing the
// client's request for the CreateCacheSecurityGroup 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 CreateCacheSecurityGroup for more information on using the CreateCacheSecurityGroup
// 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 CreateCacheSecurityGroupRequest method.
// req, resp := client.CreateCacheSecurityGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheSecurityGroup
func (c *ElastiCache) CreateCacheSecurityGroupRequest(input *CreateCacheSecurityGroupInput) (req *request.Request, output *CreateCacheSecurityGroupOutput) {
op := &request.Operation{
Name: opCreateCacheSecurityGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateCacheSecurityGroupInput{}
}
output = &CreateCacheSecurityGroupOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateCacheSecurityGroup API operation for Amazon ElastiCache.
//
// Creates a new cache security group. Use a cache security group to control
// access to one or more clusters.
//
// Cache security groups are only used when you are creating a cluster outside
// of an Amazon Virtual Private Cloud (Amazon VPC). If you are creating a cluster
// inside of a VPC, use a cache subnet group instead. For more information,
// see CreateCacheSubnetGroup (https://docs.aws.amazon.com/AmazonElastiCache/latest/APIReference/API_CreateCacheSubnetGroup.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.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation CreateCacheSecurityGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSecurityGroupAlreadyExistsFault "CacheSecurityGroupAlreadyExists"
// A cache security group with the specified name already exists.
//
// * ErrCodeCacheSecurityGroupQuotaExceededFault "QuotaExceeded.CacheSecurityGroup"
// The request cannot be processed because it would exceed the allowed number
// of cache security groups.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheSecurityGroup
func (c *ElastiCache) CreateCacheSecurityGroup(input *CreateCacheSecurityGroupInput) (*CreateCacheSecurityGroupOutput, error) {
req, out := c.CreateCacheSecurityGroupRequest(input)
return out, req.Send()
}
// CreateCacheSecurityGroupWithContext is the same as CreateCacheSecurityGroup with the addition of
// the ability to pass a context and additional request options.
//
// See CreateCacheSecurityGroup 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 *ElastiCache) CreateCacheSecurityGroupWithContext(ctx aws.Context, input *CreateCacheSecurityGroupInput, opts ...request.Option) (*CreateCacheSecurityGroupOutput, error) {
req, out := c.CreateCacheSecurityGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opCreateCacheSubnetGroup = "CreateCacheSubnetGroup"
// CreateCacheSubnetGroupRequest generates a "aws/request.Request" representing the
// client's request for the CreateCacheSubnetGroup 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 CreateCacheSubnetGroup for more information on using the CreateCacheSubnetGroup
// 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 CreateCacheSubnetGroupRequest method.
// req, resp := client.CreateCacheSubnetGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheSubnetGroup
func (c *ElastiCache) CreateCacheSubnetGroupRequest(input *CreateCacheSubnetGroupInput) (req *request.Request, output *CreateCacheSubnetGroupOutput) {
op := &request.Operation{
Name: opCreateCacheSubnetGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateCacheSubnetGroupInput{}
}
output = &CreateCacheSubnetGroupOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateCacheSubnetGroup API operation for Amazon ElastiCache.
//
// Creates a new cache subnet group.
//
// Use this parameter only when you are creating a cluster in an Amazon Virtual
// Private Cloud (Amazon 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
// the error.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation CreateCacheSubnetGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSubnetGroupAlreadyExistsFault "CacheSubnetGroupAlreadyExists"
// The requested cache subnet group name is already in use by an existing cache
// subnet group.
//
// * ErrCodeCacheSubnetGroupQuotaExceededFault "CacheSubnetGroupQuotaExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache subnet groups.
//
// * ErrCodeCacheSubnetQuotaExceededFault "CacheSubnetQuotaExceededFault"
// The request cannot be processed because it would exceed the allowed number
// of subnets in a cache subnet group.
//
// * ErrCodeInvalidSubnet "InvalidSubnet"
// An invalid subnet identifier was specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateCacheSubnetGroup
func (c *ElastiCache) CreateCacheSubnetGroup(input *CreateCacheSubnetGroupInput) (*CreateCacheSubnetGroupOutput, error) {
req, out := c.CreateCacheSubnetGroupRequest(input)
return out, req.Send()
}
// CreateCacheSubnetGroupWithContext is the same as CreateCacheSubnetGroup with the addition of
// the ability to pass a context and additional request options.
//
// See CreateCacheSubnetGroup 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 *ElastiCache) CreateCacheSubnetGroupWithContext(ctx aws.Context, input *CreateCacheSubnetGroupInput, opts ...request.Option) (*CreateCacheSubnetGroupOutput, error) {
req, out := c.CreateCacheSubnetGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opCreateReplicationGroup = "CreateReplicationGroup"
// CreateReplicationGroupRequest generates a "aws/request.Request" representing the
// client's request for the CreateReplicationGroup 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 CreateReplicationGroup for more information on using the CreateReplicationGroup
// 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 CreateReplicationGroupRequest method.
// req, resp := client.CreateReplicationGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateReplicationGroup
func (c *ElastiCache) CreateReplicationGroupRequest(input *CreateReplicationGroupInput) (req *request.Request, output *CreateReplicationGroupOutput) {
op := &request.Operation{
Name: opCreateReplicationGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateReplicationGroupInput{}
}
output = &CreateReplicationGroupOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateReplicationGroup API operation for Amazon ElastiCache.
//
// Creates a Redis (cluster mode disabled) or a Redis (cluster mode enabled)
// replication group.
//
// A Redis (cluster mode disabled) replication group is a collection of clusters,
// where one of the clusters is a read/write primary and the others are read-only
// replicas. Writes to the primary are asynchronously propagated to the replicas.
//
// A Redis (cluster mode enabled) replication group is a collection of 1 to
// 90 node groups (shards). Each node group (shard) has one read/write primary
// node and up to 5 read-only replica nodes. Writes to the primary are asynchronously
// propagated to the replicas. Redis (cluster mode enabled) replication groups
// partition the data across node groups (shards).
//
// When a Redis (cluster mode disabled) replication group has been successfully
// created, you can add one or more read replicas to it, up to a total of 5
// read replicas. You cannot alter a Redis (cluster mode enabled) replication
// group after it has been created. However, if you need to increase or decrease
// the number of node groups (console: shards), you can avail yourself of ElastiCache
// for Redis' enhanced backup and restore. For more information, see Restoring
// From a Backup with Cluster Resizing (https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/backups-restoring.html)
// in the ElastiCache User Guide.
//
// This operation is valid for Redis only.
//
// 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 ElastiCache's
// API operation CreateReplicationGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheClusterNotFoundFault "CacheClusterNotFound"
// The requested cluster ID does not refer to an existing cluster.
//
// * ErrCodeInvalidCacheClusterStateFault "InvalidCacheClusterState"
// The requested cluster is not in the available state.
//
// * ErrCodeReplicationGroupAlreadyExistsFault "ReplicationGroupAlreadyExists"
// The specified replication group already exists.
//
// * ErrCodeInsufficientCacheClusterCapacityFault "InsufficientCacheClusterCapacity"
// The requested cache node type is not available in the specified Availability
// Zone. For more information, see InsufficientCacheClusterCapacity (http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ErrorMessages.html#ErrorMessages.INSUFFICIENT_CACHE_CLUSTER_CAPACITY)
// in the ElastiCache User Guide.
//
// * ErrCodeCacheSecurityGroupNotFoundFault "CacheSecurityGroupNotFound"
// The requested cache security group name does not refer to an existing cache
// security group.
//
// * ErrCodeCacheSubnetGroupNotFoundFault "CacheSubnetGroupNotFoundFault"
// The requested cache subnet group name does not refer to an existing cache
// subnet group.
//
// * ErrCodeClusterQuotaForCustomerExceededFault "ClusterQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of clusters per customer.
//
// * ErrCodeNodeQuotaForClusterExceededFault "NodeQuotaForClusterExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache nodes in a single cluster.
//
// * ErrCodeNodeQuotaForCustomerExceededFault "NodeQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache nodes per customer.
//
// * ErrCodeCacheParameterGroupNotFoundFault "CacheParameterGroupNotFound"
// The requested cache parameter group name does not refer to an existing cache
// parameter group.
//
// * ErrCodeInvalidVPCNetworkStateFault "InvalidVPCNetworkStateFault"
// The VPC network is in an invalid state.
//
// * ErrCodeTagQuotaPerResourceExceeded "TagQuotaPerResourceExceeded"
// The request cannot be processed because it would cause the resource to have
// more than the allowed number of tags. The maximum number of tags permitted
// on a resource is 50.
//
// * ErrCodeNodeGroupsPerReplicationGroupQuotaExceededFault "NodeGroupsPerReplicationGroupQuotaExceeded"
// The request cannot be processed because it would exceed the maximum allowed
// number of node groups (shards) in a single replication group. The default
// maximum is 90
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateReplicationGroup
func (c *ElastiCache) CreateReplicationGroup(input *CreateReplicationGroupInput) (*CreateReplicationGroupOutput, error) {
req, out := c.CreateReplicationGroupRequest(input)
return out, req.Send()
}
// CreateReplicationGroupWithContext is the same as CreateReplicationGroup with the addition of
// the ability to pass a context and additional request options.
//
// See CreateReplicationGroup 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 *ElastiCache) CreateReplicationGroupWithContext(ctx aws.Context, input *CreateReplicationGroupInput, opts ...request.Option) (*CreateReplicationGroupOutput, error) {
req, out := c.CreateReplicationGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
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.
//
// Use "Send" method on 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 CreateSnapshot for more information on using the CreateSnapshot
// 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 CreateSnapshotRequest method.
// req, resp := client.CreateSnapshotRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateSnapshot
func (c *ElastiCache) CreateSnapshotRequest(input *CreateSnapshotInput) (req *request.Request, output *CreateSnapshotOutput) {
op := &request.Operation{
Name: opCreateSnapshot,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateSnapshotInput{}
}
output = &CreateSnapshotOutput{}
req = c.newRequest(op, input, output)
return
}
// CreateSnapshot API operation for Amazon ElastiCache.
//
// Creates a copy of an entire cluster or replication group at a specific moment
// in time.
//
// This operation is valid for Redis only.
//
// 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 ElastiCache's
// API operation CreateSnapshot for usage and error information.
//
// Returned Error Codes:
// * ErrCodeSnapshotAlreadyExistsFault "SnapshotAlreadyExistsFault"
// You already have a snapshot with the given name.
//
// * ErrCodeCacheClusterNotFoundFault "CacheClusterNotFound"
// The requested cluster ID does not refer to an existing cluster.
//
// * ErrCodeReplicationGroupNotFoundFault "ReplicationGroupNotFoundFault"
// The specified replication group does not exist.
//
// * ErrCodeInvalidCacheClusterStateFault "InvalidCacheClusterState"
// The requested cluster is not in the available state.
//
// * ErrCodeInvalidReplicationGroupStateFault "InvalidReplicationGroupState"
// The requested replication group is not in the available state.
//
// * ErrCodeSnapshotQuotaExceededFault "SnapshotQuotaExceededFault"
// The request cannot be processed because it would exceed the maximum number
// of snapshots.
//
// * ErrCodeSnapshotFeatureNotSupportedFault "SnapshotFeatureNotSupportedFault"
// You attempted one of the following operations:
//
// * Creating a snapshot of a Redis cluster running on a cache.t1.micro cache
// node.
//
// * Creating a snapshot of a cluster that is running Memcached rather than
// Redis.
//
// Neither of these are supported by ElastiCache.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/CreateSnapshot
func (c *ElastiCache) CreateSnapshot(input *CreateSnapshotInput) (*CreateSnapshotOutput, error) {
req, out := c.CreateSnapshotRequest(input)
return out, req.Send()
}
// CreateSnapshotWithContext is the same as CreateSnapshot with the addition of
// the ability to pass a context and additional request options.
//
// See CreateSnapshot 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 *ElastiCache) CreateSnapshotWithContext(ctx aws.Context, input *CreateSnapshotInput, opts ...request.Option) (*CreateSnapshotOutput, error) {
req, out := c.CreateSnapshotRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDecreaseReplicaCount = "DecreaseReplicaCount"
// DecreaseReplicaCountRequest generates a "aws/request.Request" representing the
// client's request for the DecreaseReplicaCount 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 DecreaseReplicaCount for more information on using the DecreaseReplicaCount
// 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 DecreaseReplicaCountRequest method.
// req, resp := client.DecreaseReplicaCountRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DecreaseReplicaCount
func (c *ElastiCache) DecreaseReplicaCountRequest(input *DecreaseReplicaCountInput) (req *request.Request, output *DecreaseReplicaCountOutput) {
op := &request.Operation{
Name: opDecreaseReplicaCount,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DecreaseReplicaCountInput{}
}
output = &DecreaseReplicaCountOutput{}
req = c.newRequest(op, input, output)
return
}
// DecreaseReplicaCount API operation for Amazon ElastiCache.
//
// Dynamically decreases the number of replics in a Redis (cluster mode disabled)
// replication group or the number of replica nodes in one or more node groups
// (shards) of a Redis (cluster mode enabled) replication group. This operation
// is performed with no cluster down 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
// the error.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation DecreaseReplicaCount for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReplicationGroupNotFoundFault "ReplicationGroupNotFoundFault"
// The specified replication group does not exist.
//
// * ErrCodeInvalidReplicationGroupStateFault "InvalidReplicationGroupState"
// The requested replication group is not in the available state.
//
// * ErrCodeInvalidCacheClusterStateFault "InvalidCacheClusterState"
// The requested cluster is not in the available state.
//
// * ErrCodeInvalidVPCNetworkStateFault "InvalidVPCNetworkStateFault"
// The VPC network is in an invalid state.
//
// * ErrCodeInsufficientCacheClusterCapacityFault "InsufficientCacheClusterCapacity"
// The requested cache node type is not available in the specified Availability
// Zone. For more information, see InsufficientCacheClusterCapacity (http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/ErrorMessages.html#ErrorMessages.INSUFFICIENT_CACHE_CLUSTER_CAPACITY)
// in the ElastiCache User Guide.
//
// * ErrCodeClusterQuotaForCustomerExceededFault "ClusterQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of clusters per customer.
//
// * ErrCodeNodeGroupsPerReplicationGroupQuotaExceededFault "NodeGroupsPerReplicationGroupQuotaExceeded"
// The request cannot be processed because it would exceed the maximum allowed
// number of node groups (shards) in a single replication group. The default
// maximum is 90
//
// * ErrCodeNodeQuotaForCustomerExceededFault "NodeQuotaForCustomerExceeded"
// The request cannot be processed because it would exceed the allowed number
// of cache nodes per customer.
//
// * ErrCodeServiceLinkedRoleNotFoundFault "ServiceLinkedRoleNotFoundFault"
// The specified service linked role (SLR) was not found.
//
// * ErrCodeNoOperationFault "NoOperationFault"
// The operation was not performed because no changes were required.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DecreaseReplicaCount
func (c *ElastiCache) DecreaseReplicaCount(input *DecreaseReplicaCountInput) (*DecreaseReplicaCountOutput, error) {
req, out := c.DecreaseReplicaCountRequest(input)
return out, req.Send()
}
// DecreaseReplicaCountWithContext is the same as DecreaseReplicaCount with the addition of
// the ability to pass a context and additional request options.
//
// See DecreaseReplicaCount 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 *ElastiCache) DecreaseReplicaCountWithContext(ctx aws.Context, input *DecreaseReplicaCountInput, opts ...request.Option) (*DecreaseReplicaCountOutput, error) {
req, out := c.DecreaseReplicaCountRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDeleteCacheCluster = "DeleteCacheCluster"
// DeleteCacheClusterRequest generates a "aws/request.Request" representing the
// client's request for the DeleteCacheCluster 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 DeleteCacheCluster for more information on using the DeleteCacheCluster
// 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 DeleteCacheClusterRequest method.
// req, resp := client.DeleteCacheClusterRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheCluster
func (c *ElastiCache) DeleteCacheClusterRequest(input *DeleteCacheClusterInput) (req *request.Request, output *DeleteCacheClusterOutput) {
op := &request.Operation{
Name: opDeleteCacheCluster,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteCacheClusterInput{}
}
output = &DeleteCacheClusterOutput{}
req = c.newRequest(op, input, output)
return
}
// DeleteCacheCluster API operation for Amazon ElastiCache.
//
// Deletes a previously provisioned cluster. DeleteCacheCluster deletes all
// associated cache nodes, node endpoints and the cluster itself. When you receive
// a successful response from this operation, Amazon ElastiCache immediately
// begins deleting the cluster; you cannot cancel or revert this operation.
//
// This operation is not valid for:
//
// * Redis (cluster mode enabled) clusters
//
// * A cluster that is the last read replica of a replication group
//
// * A node group (shard) that has Multi-AZ mode enabled
//
// * A cluster from a Redis (cluster mode enabled) replication group
//
// * A cluster that is not in the available 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
// the error.
//
// See the AWS API reference guide for Amazon ElastiCache's
// API operation DeleteCacheCluster for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheClusterNotFoundFault "CacheClusterNotFound"
// The requested cluster ID does not refer to an existing cluster.
//
// * ErrCodeInvalidCacheClusterStateFault "InvalidCacheClusterState"
// The requested cluster is not in the available state.
//
// * ErrCodeSnapshotAlreadyExistsFault "SnapshotAlreadyExistsFault"
// You already have a snapshot with the given name.
//
// * ErrCodeSnapshotFeatureNotSupportedFault "SnapshotFeatureNotSupportedFault"
// You attempted one of the following operations:
//
// * Creating a snapshot of a Redis cluster running on a cache.t1.micro cache
// node.
//
// * Creating a snapshot of a cluster that is running Memcached rather than
// Redis.
//
// Neither of these are supported by ElastiCache.
//
// * ErrCodeSnapshotQuotaExceededFault "SnapshotQuotaExceededFault"
// The request cannot be processed because it would exceed the maximum number
// of snapshots.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheCluster
func (c *ElastiCache) DeleteCacheCluster(input *DeleteCacheClusterInput) (*DeleteCacheClusterOutput, error) {
req, out := c.DeleteCacheClusterRequest(input)
return out, req.Send()
}
// DeleteCacheClusterWithContext is the same as DeleteCacheCluster with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteCacheCluster 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 *ElastiCache) DeleteCacheClusterWithContext(ctx aws.Context, input *DeleteCacheClusterInput, opts ...request.Option) (*DeleteCacheClusterOutput, error) {
req, out := c.DeleteCacheClusterRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDeleteCacheParameterGroup = "DeleteCacheParameterGroup"
// DeleteCacheParameterGroupRequest generates a "aws/request.Request" representing the
// client's request for the DeleteCacheParameterGroup 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 DeleteCacheParameterGroup for more information on using the DeleteCacheParameterGroup
// 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 DeleteCacheParameterGroupRequest method.
// req, resp := client.DeleteCacheParameterGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheParameterGroup
func (c *ElastiCache) DeleteCacheParameterGroupRequest(input *DeleteCacheParameterGroupInput) (req *request.Request, output *DeleteCacheParameterGroupOutput) {
op := &request.Operation{
Name: opDeleteCacheParameterGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteCacheParameterGroupInput{}
}
output = &DeleteCacheParameterGroupOutput{}
req = c.newRequest(op, input, output)
req.Handlers.Unmarshal.Swap(query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
return
}
// DeleteCacheParameterGroup API operation for Amazon ElastiCache.
//
// Deletes the specified cache parameter group. You cannot delete a cache parameter
// group if it is associated with any cache clusters.
//
// 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 ElastiCache's
// API operation DeleteCacheParameterGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeInvalidCacheParameterGroupStateFault "InvalidCacheParameterGroupState"
// The current state of the cache parameter group does not allow the requested
// operation to occur.
//
// * ErrCodeCacheParameterGroupNotFoundFault "CacheParameterGroupNotFound"
// The requested cache parameter group name does not refer to an existing cache
// parameter group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheParameterGroup
func (c *ElastiCache) DeleteCacheParameterGroup(input *DeleteCacheParameterGroupInput) (*DeleteCacheParameterGroupOutput, error) {
req, out := c.DeleteCacheParameterGroupRequest(input)
return out, req.Send()
}
// DeleteCacheParameterGroupWithContext is the same as DeleteCacheParameterGroup with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteCacheParameterGroup 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 *ElastiCache) DeleteCacheParameterGroupWithContext(ctx aws.Context, input *DeleteCacheParameterGroupInput, opts ...request.Option) (*DeleteCacheParameterGroupOutput, error) {
req, out := c.DeleteCacheParameterGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDeleteCacheSecurityGroup = "DeleteCacheSecurityGroup"
// DeleteCacheSecurityGroupRequest generates a "aws/request.Request" representing the
// client's request for the DeleteCacheSecurityGroup 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 DeleteCacheSecurityGroup for more information on using the DeleteCacheSecurityGroup
// 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 DeleteCacheSecurityGroupRequest method.
// req, resp := client.DeleteCacheSecurityGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheSecurityGroup
func (c *ElastiCache) DeleteCacheSecurityGroupRequest(input *DeleteCacheSecurityGroupInput) (req *request.Request, output *DeleteCacheSecurityGroupOutput) {
op := &request.Operation{
Name: opDeleteCacheSecurityGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteCacheSecurityGroupInput{}
}
output = &DeleteCacheSecurityGroupOutput{}
req = c.newRequest(op, input, output)
req.Handlers.Unmarshal.Swap(query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
return
}
// DeleteCacheSecurityGroup API operation for Amazon ElastiCache.
//
// Deletes a cache security group.
//
// You cannot delete a cache security group if it is associated with any clusters.
//
// 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 ElastiCache's
// API operation DeleteCacheSecurityGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeInvalidCacheSecurityGroupStateFault "InvalidCacheSecurityGroupState"
// The current state of the cache security group does not allow deletion.
//
// * ErrCodeCacheSecurityGroupNotFoundFault "CacheSecurityGroupNotFound"
// The requested cache security group name does not refer to an existing cache
// security group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheSecurityGroup
func (c *ElastiCache) DeleteCacheSecurityGroup(input *DeleteCacheSecurityGroupInput) (*DeleteCacheSecurityGroupOutput, error) {
req, out := c.DeleteCacheSecurityGroupRequest(input)
return out, req.Send()
}
// DeleteCacheSecurityGroupWithContext is the same as DeleteCacheSecurityGroup with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteCacheSecurityGroup 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 *ElastiCache) DeleteCacheSecurityGroupWithContext(ctx aws.Context, input *DeleteCacheSecurityGroupInput, opts ...request.Option) (*DeleteCacheSecurityGroupOutput, error) {
req, out := c.DeleteCacheSecurityGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDeleteCacheSubnetGroup = "DeleteCacheSubnetGroup"
// DeleteCacheSubnetGroupRequest generates a "aws/request.Request" representing the
// client's request for the DeleteCacheSubnetGroup 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 DeleteCacheSubnetGroup for more information on using the DeleteCacheSubnetGroup
// 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 DeleteCacheSubnetGroupRequest method.
// req, resp := client.DeleteCacheSubnetGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheSubnetGroup
func (c *ElastiCache) DeleteCacheSubnetGroupRequest(input *DeleteCacheSubnetGroupInput) (req *request.Request, output *DeleteCacheSubnetGroupOutput) {
op := &request.Operation{
Name: opDeleteCacheSubnetGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteCacheSubnetGroupInput{}
}
output = &DeleteCacheSubnetGroupOutput{}
req = c.newRequest(op, input, output)
req.Handlers.Unmarshal.Swap(query.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
return
}
// DeleteCacheSubnetGroup API operation for Amazon ElastiCache.
//
// Deletes a cache subnet group.
//
// You cannot delete a cache subnet group if it is associated with any clusters.
//
// 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 ElastiCache's
// API operation DeleteCacheSubnetGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSubnetGroupInUse "CacheSubnetGroupInUse"
// The requested cache subnet group is currently in use.
//
// * ErrCodeCacheSubnetGroupNotFoundFault "CacheSubnetGroupNotFoundFault"
// The requested cache subnet group name does not refer to an existing cache
// subnet group.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteCacheSubnetGroup
func (c *ElastiCache) DeleteCacheSubnetGroup(input *DeleteCacheSubnetGroupInput) (*DeleteCacheSubnetGroupOutput, error) {
req, out := c.DeleteCacheSubnetGroupRequest(input)
return out, req.Send()
}
// DeleteCacheSubnetGroupWithContext is the same as DeleteCacheSubnetGroup with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteCacheSubnetGroup 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 *ElastiCache) DeleteCacheSubnetGroupWithContext(ctx aws.Context, input *DeleteCacheSubnetGroupInput, opts ...request.Option) (*DeleteCacheSubnetGroupOutput, error) {
req, out := c.DeleteCacheSubnetGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDeleteReplicationGroup = "DeleteReplicationGroup"
// DeleteReplicationGroupRequest generates a "aws/request.Request" representing the
// client's request for the DeleteReplicationGroup 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 DeleteReplicationGroup for more information on using the DeleteReplicationGroup
// 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 DeleteReplicationGroupRequest method.
// req, resp := client.DeleteReplicationGroupRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteReplicationGroup
func (c *ElastiCache) DeleteReplicationGroupRequest(input *DeleteReplicationGroupInput) (req *request.Request, output *DeleteReplicationGroupOutput) {
op := &request.Operation{
Name: opDeleteReplicationGroup,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteReplicationGroupInput{}
}
output = &DeleteReplicationGroupOutput{}
req = c.newRequest(op, input, output)
return
}
// DeleteReplicationGroup API operation for Amazon ElastiCache.
//
// Deletes an existing replication group. By default, this operation deletes
// the entire replication group, including the primary/primaries and all of
// the read replicas. If the replication group has only one primary, you can
// optionally delete only the read replicas, while retaining the primary by
// setting RetainPrimaryCluster=true.
//
// When you receive a successful response from this operation, Amazon ElastiCache
// immediately begins deleting the selected resources; you cannot cancel or
// revert this operation.
//
// This operation is valid for Redis only.
//
// 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 ElastiCache's
// API operation DeleteReplicationGroup for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReplicationGroupNotFoundFault "ReplicationGroupNotFoundFault"
// The specified replication group does not exist.
//
// * ErrCodeInvalidReplicationGroupStateFault "InvalidReplicationGroupState"
// The requested replication group is not in the available state.
//
// * ErrCodeSnapshotAlreadyExistsFault "SnapshotAlreadyExistsFault"
// You already have a snapshot with the given name.
//
// * ErrCodeSnapshotFeatureNotSupportedFault "SnapshotFeatureNotSupportedFault"
// You attempted one of the following operations:
//
// * Creating a snapshot of a Redis cluster running on a cache.t1.micro cache
// node.
//
// * Creating a snapshot of a cluster that is running Memcached rather than
// Redis.
//
// Neither of these are supported by ElastiCache.
//
// * ErrCodeSnapshotQuotaExceededFault "SnapshotQuotaExceededFault"
// The request cannot be processed because it would exceed the maximum number
// of snapshots.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteReplicationGroup
func (c *ElastiCache) DeleteReplicationGroup(input *DeleteReplicationGroupInput) (*DeleteReplicationGroupOutput, error) {
req, out := c.DeleteReplicationGroupRequest(input)
return out, req.Send()
}
// DeleteReplicationGroupWithContext is the same as DeleteReplicationGroup with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteReplicationGroup 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 *ElastiCache) DeleteReplicationGroupWithContext(ctx aws.Context, input *DeleteReplicationGroupInput, opts ...request.Option) (*DeleteReplicationGroupOutput, error) {
req, out := c.DeleteReplicationGroupRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
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.
//
// Use "Send" method on 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 DeleteSnapshot for more information on using the DeleteSnapshot
// 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 DeleteSnapshotRequest method.
// req, resp := client.DeleteSnapshotRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteSnapshot
func (c *ElastiCache) DeleteSnapshotRequest(input *DeleteSnapshotInput) (req *request.Request, output *DeleteSnapshotOutput) {
op := &request.Operation{
Name: opDeleteSnapshot,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteSnapshotInput{}
}
output = &DeleteSnapshotOutput{}
req = c.newRequest(op, input, output)
return
}
// DeleteSnapshot API operation for Amazon ElastiCache.
//
// Deletes an existing snapshot. When you receive a successful response from
// this operation, ElastiCache immediately begins deleting the snapshot; you
// cannot cancel or revert this operation.
//
// This operation is valid for Redis only.
//
// 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 ElastiCache's
// API operation DeleteSnapshot for usage and error information.
//
// Returned Error Codes:
// * ErrCodeSnapshotNotFoundFault "SnapshotNotFoundFault"
// The requested snapshot name does not refer to an existing snapshot.
//
// * ErrCodeInvalidSnapshotStateFault "InvalidSnapshotState"
// The current state of the snapshot does not allow the requested operation
// to occur.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DeleteSnapshot
func (c *ElastiCache) DeleteSnapshot(input *DeleteSnapshotInput) (*DeleteSnapshotOutput, error) {
req, out := c.DeleteSnapshotRequest(input)
return out, req.Send()
}
// DeleteSnapshotWithContext is the same as DeleteSnapshot with the addition of
// the ability to pass a context and additional request options.
//
// See DeleteSnapshot 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 *ElastiCache) DeleteSnapshotWithContext(ctx aws.Context, input *DeleteSnapshotInput, opts ...request.Option) (*DeleteSnapshotOutput, error) {
req, out := c.DeleteSnapshotRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
const opDescribeCacheClusters = "DescribeCacheClusters"
// DescribeCacheClustersRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheClusters 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 DescribeCacheClusters for more information on using the DescribeCacheClusters
// 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 DescribeCacheClustersRequest method.
// req, resp := client.DescribeCacheClustersRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheClusters
func (c *ElastiCache) DescribeCacheClustersRequest(input *DescribeCacheClustersInput) (req *request.Request, output *DescribeCacheClustersOutput) {
op := &request.Operation{
Name: opDescribeCacheClusters,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheClustersInput{}
}
output = &DescribeCacheClustersOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheClusters API operation for Amazon ElastiCache.
//
// Returns information about all provisioned clusters if no cluster identifier
// is specified, or about a specific cache cluster if a cluster identifier is
// supplied.
//
// By default, abbreviated information about the clusters is returned. You can
// use the optional ShowCacheNodeInfo flag to retrieve detailed information
// about the cache nodes associated with the clusters. These details include
// the DNS address and port for the cache node endpoint.
//
// If the cluster is in the creating state, only cluster-level information is
// displayed until all of the nodes are successfully provisioned.
//
// If the cluster is in the deleting state, only cluster-level information is
// displayed.
//
// If cache nodes are currently being added to the cluster, node endpoint information
// and creation time for the additional nodes are not displayed until they are
// completely provisioned. When the cluster state is available, the cluster
// is ready for use.
//
// If cache nodes are currently being removed from the cluster, no endpoint
// information for the removed nodes is displayed.
//
// 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 ElastiCache's
// API operation DescribeCacheClusters for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheClusterNotFoundFault "CacheClusterNotFound"
// The requested cluster ID does not refer to an existing cluster.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheClusters
func (c *ElastiCache) DescribeCacheClusters(input *DescribeCacheClustersInput) (*DescribeCacheClustersOutput, error) {
req, out := c.DescribeCacheClustersRequest(input)
return out, req.Send()
}
// DescribeCacheClustersWithContext is the same as DescribeCacheClusters with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheClusters 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 *ElastiCache) DescribeCacheClustersWithContext(ctx aws.Context, input *DescribeCacheClustersInput, opts ...request.Option) (*DescribeCacheClustersOutput, error) {
req, out := c.DescribeCacheClustersRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheClustersPages iterates over the pages of a DescribeCacheClusters operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheClusters 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 DescribeCacheClusters operation.
// pageNum := 0
// err := client.DescribeCacheClustersPages(params,
// func(page *elasticache.DescribeCacheClustersOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheClustersPages(input *DescribeCacheClustersInput, fn func(*DescribeCacheClustersOutput, bool) bool) error {
return c.DescribeCacheClustersPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheClustersPagesWithContext same as DescribeCacheClustersPages 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 *ElastiCache) DescribeCacheClustersPagesWithContext(ctx aws.Context, input *DescribeCacheClustersInput, fn func(*DescribeCacheClustersOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheClustersInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheClustersRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheClustersOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeCacheEngineVersions = "DescribeCacheEngineVersions"
// DescribeCacheEngineVersionsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheEngineVersions 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 DescribeCacheEngineVersions for more information on using the DescribeCacheEngineVersions
// 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 DescribeCacheEngineVersionsRequest method.
// req, resp := client.DescribeCacheEngineVersionsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheEngineVersions
func (c *ElastiCache) DescribeCacheEngineVersionsRequest(input *DescribeCacheEngineVersionsInput) (req *request.Request, output *DescribeCacheEngineVersionsOutput) {
op := &request.Operation{
Name: opDescribeCacheEngineVersions,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheEngineVersionsInput{}
}
output = &DescribeCacheEngineVersionsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheEngineVersions API operation for Amazon ElastiCache.
//
// Returns a list of the available cache engines and their versions.
//
// 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 ElastiCache's
// API operation DescribeCacheEngineVersions for usage and error information.
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheEngineVersions
func (c *ElastiCache) DescribeCacheEngineVersions(input *DescribeCacheEngineVersionsInput) (*DescribeCacheEngineVersionsOutput, error) {
req, out := c.DescribeCacheEngineVersionsRequest(input)
return out, req.Send()
}
// DescribeCacheEngineVersionsWithContext is the same as DescribeCacheEngineVersions with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheEngineVersions 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 *ElastiCache) DescribeCacheEngineVersionsWithContext(ctx aws.Context, input *DescribeCacheEngineVersionsInput, opts ...request.Option) (*DescribeCacheEngineVersionsOutput, error) {
req, out := c.DescribeCacheEngineVersionsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheEngineVersionsPages iterates over the pages of a DescribeCacheEngineVersions operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheEngineVersions 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 DescribeCacheEngineVersions operation.
// pageNum := 0
// err := client.DescribeCacheEngineVersionsPages(params,
// func(page *elasticache.DescribeCacheEngineVersionsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheEngineVersionsPages(input *DescribeCacheEngineVersionsInput, fn func(*DescribeCacheEngineVersionsOutput, bool) bool) error {
return c.DescribeCacheEngineVersionsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheEngineVersionsPagesWithContext same as DescribeCacheEngineVersionsPages 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 *ElastiCache) DescribeCacheEngineVersionsPagesWithContext(ctx aws.Context, input *DescribeCacheEngineVersionsInput, fn func(*DescribeCacheEngineVersionsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheEngineVersionsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheEngineVersionsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheEngineVersionsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeCacheParameterGroups = "DescribeCacheParameterGroups"
// DescribeCacheParameterGroupsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheParameterGroups 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 DescribeCacheParameterGroups for more information on using the DescribeCacheParameterGroups
// 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 DescribeCacheParameterGroupsRequest method.
// req, resp := client.DescribeCacheParameterGroupsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheParameterGroups
func (c *ElastiCache) DescribeCacheParameterGroupsRequest(input *DescribeCacheParameterGroupsInput) (req *request.Request, output *DescribeCacheParameterGroupsOutput) {
op := &request.Operation{
Name: opDescribeCacheParameterGroups,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheParameterGroupsInput{}
}
output = &DescribeCacheParameterGroupsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheParameterGroups API operation for Amazon ElastiCache.
//
// Returns a list of cache parameter group descriptions. If a cache parameter
// group name is specified, the list contains only the descriptions for that
// group.
//
// 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 ElastiCache's
// API operation DescribeCacheParameterGroups for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheParameterGroupNotFoundFault "CacheParameterGroupNotFound"
// The requested cache parameter group name does not refer to an existing cache
// parameter group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheParameterGroups
func (c *ElastiCache) DescribeCacheParameterGroups(input *DescribeCacheParameterGroupsInput) (*DescribeCacheParameterGroupsOutput, error) {
req, out := c.DescribeCacheParameterGroupsRequest(input)
return out, req.Send()
}
// DescribeCacheParameterGroupsWithContext is the same as DescribeCacheParameterGroups with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheParameterGroups 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 *ElastiCache) DescribeCacheParameterGroupsWithContext(ctx aws.Context, input *DescribeCacheParameterGroupsInput, opts ...request.Option) (*DescribeCacheParameterGroupsOutput, error) {
req, out := c.DescribeCacheParameterGroupsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheParameterGroupsPages iterates over the pages of a DescribeCacheParameterGroups operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheParameterGroups 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 DescribeCacheParameterGroups operation.
// pageNum := 0
// err := client.DescribeCacheParameterGroupsPages(params,
// func(page *elasticache.DescribeCacheParameterGroupsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheParameterGroupsPages(input *DescribeCacheParameterGroupsInput, fn func(*DescribeCacheParameterGroupsOutput, bool) bool) error {
return c.DescribeCacheParameterGroupsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheParameterGroupsPagesWithContext same as DescribeCacheParameterGroupsPages 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 *ElastiCache) DescribeCacheParameterGroupsPagesWithContext(ctx aws.Context, input *DescribeCacheParameterGroupsInput, fn func(*DescribeCacheParameterGroupsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheParameterGroupsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheParameterGroupsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheParameterGroupsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeCacheParameters = "DescribeCacheParameters"
// DescribeCacheParametersRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheParameters 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 DescribeCacheParameters for more information on using the DescribeCacheParameters
// 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 DescribeCacheParametersRequest method.
// req, resp := client.DescribeCacheParametersRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheParameters
func (c *ElastiCache) DescribeCacheParametersRequest(input *DescribeCacheParametersInput) (req *request.Request, output *DescribeCacheParametersOutput) {
op := &request.Operation{
Name: opDescribeCacheParameters,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheParametersInput{}
}
output = &DescribeCacheParametersOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheParameters API operation for Amazon ElastiCache.
//
// Returns the detailed parameter list for a particular cache parameter group.
//
// 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 ElastiCache's
// API operation DescribeCacheParameters for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheParameterGroupNotFoundFault "CacheParameterGroupNotFound"
// The requested cache parameter group name does not refer to an existing cache
// parameter group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheParameters
func (c *ElastiCache) DescribeCacheParameters(input *DescribeCacheParametersInput) (*DescribeCacheParametersOutput, error) {
req, out := c.DescribeCacheParametersRequest(input)
return out, req.Send()
}
// DescribeCacheParametersWithContext is the same as DescribeCacheParameters with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheParameters 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 *ElastiCache) DescribeCacheParametersWithContext(ctx aws.Context, input *DescribeCacheParametersInput, opts ...request.Option) (*DescribeCacheParametersOutput, error) {
req, out := c.DescribeCacheParametersRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheParametersPages iterates over the pages of a DescribeCacheParameters operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheParameters 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 DescribeCacheParameters operation.
// pageNum := 0
// err := client.DescribeCacheParametersPages(params,
// func(page *elasticache.DescribeCacheParametersOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheParametersPages(input *DescribeCacheParametersInput, fn func(*DescribeCacheParametersOutput, bool) bool) error {
return c.DescribeCacheParametersPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheParametersPagesWithContext same as DescribeCacheParametersPages 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 *ElastiCache) DescribeCacheParametersPagesWithContext(ctx aws.Context, input *DescribeCacheParametersInput, fn func(*DescribeCacheParametersOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheParametersInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheParametersRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheParametersOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeCacheSecurityGroups = "DescribeCacheSecurityGroups"
// DescribeCacheSecurityGroupsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheSecurityGroups 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 DescribeCacheSecurityGroups for more information on using the DescribeCacheSecurityGroups
// 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 DescribeCacheSecurityGroupsRequest method.
// req, resp := client.DescribeCacheSecurityGroupsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheSecurityGroups
func (c *ElastiCache) DescribeCacheSecurityGroupsRequest(input *DescribeCacheSecurityGroupsInput) (req *request.Request, output *DescribeCacheSecurityGroupsOutput) {
op := &request.Operation{
Name: opDescribeCacheSecurityGroups,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheSecurityGroupsInput{}
}
output = &DescribeCacheSecurityGroupsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheSecurityGroups API operation for Amazon ElastiCache.
//
// Returns a list of cache security group descriptions. If a cache security
// group name is specified, the list contains only the description of that group.
// This applicable only when you have ElastiCache in Classic setup
//
// 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 ElastiCache's
// API operation DescribeCacheSecurityGroups for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSecurityGroupNotFoundFault "CacheSecurityGroupNotFound"
// The requested cache security group name does not refer to an existing cache
// security group.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheSecurityGroups
func (c *ElastiCache) DescribeCacheSecurityGroups(input *DescribeCacheSecurityGroupsInput) (*DescribeCacheSecurityGroupsOutput, error) {
req, out := c.DescribeCacheSecurityGroupsRequest(input)
return out, req.Send()
}
// DescribeCacheSecurityGroupsWithContext is the same as DescribeCacheSecurityGroups with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheSecurityGroups 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 *ElastiCache) DescribeCacheSecurityGroupsWithContext(ctx aws.Context, input *DescribeCacheSecurityGroupsInput, opts ...request.Option) (*DescribeCacheSecurityGroupsOutput, error) {
req, out := c.DescribeCacheSecurityGroupsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheSecurityGroupsPages iterates over the pages of a DescribeCacheSecurityGroups operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheSecurityGroups 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 DescribeCacheSecurityGroups operation.
// pageNum := 0
// err := client.DescribeCacheSecurityGroupsPages(params,
// func(page *elasticache.DescribeCacheSecurityGroupsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheSecurityGroupsPages(input *DescribeCacheSecurityGroupsInput, fn func(*DescribeCacheSecurityGroupsOutput, bool) bool) error {
return c.DescribeCacheSecurityGroupsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheSecurityGroupsPagesWithContext same as DescribeCacheSecurityGroupsPages 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 *ElastiCache) DescribeCacheSecurityGroupsPagesWithContext(ctx aws.Context, input *DescribeCacheSecurityGroupsInput, fn func(*DescribeCacheSecurityGroupsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheSecurityGroupsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheSecurityGroupsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheSecurityGroupsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeCacheSubnetGroups = "DescribeCacheSubnetGroups"
// DescribeCacheSubnetGroupsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeCacheSubnetGroups 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 DescribeCacheSubnetGroups for more information on using the DescribeCacheSubnetGroups
// 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 DescribeCacheSubnetGroupsRequest method.
// req, resp := client.DescribeCacheSubnetGroupsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheSubnetGroups
func (c *ElastiCache) DescribeCacheSubnetGroupsRequest(input *DescribeCacheSubnetGroupsInput) (req *request.Request, output *DescribeCacheSubnetGroupsOutput) {
op := &request.Operation{
Name: opDescribeCacheSubnetGroups,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeCacheSubnetGroupsInput{}
}
output = &DescribeCacheSubnetGroupsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeCacheSubnetGroups API operation for Amazon ElastiCache.
//
// Returns a list of cache subnet group descriptions. If a subnet group name
// is specified, the list contains only the description of that group. This
// is applicable only when you have ElastiCache in VPC setup. All ElastiCache
// clusters now launch in VPC by default.
//
// 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 ElastiCache's
// API operation DescribeCacheSubnetGroups for usage and error information.
//
// Returned Error Codes:
// * ErrCodeCacheSubnetGroupNotFoundFault "CacheSubnetGroupNotFoundFault"
// The requested cache subnet group name does not refer to an existing cache
// subnet group.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeCacheSubnetGroups
func (c *ElastiCache) DescribeCacheSubnetGroups(input *DescribeCacheSubnetGroupsInput) (*DescribeCacheSubnetGroupsOutput, error) {
req, out := c.DescribeCacheSubnetGroupsRequest(input)
return out, req.Send()
}
// DescribeCacheSubnetGroupsWithContext is the same as DescribeCacheSubnetGroups with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeCacheSubnetGroups 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 *ElastiCache) DescribeCacheSubnetGroupsWithContext(ctx aws.Context, input *DescribeCacheSubnetGroupsInput, opts ...request.Option) (*DescribeCacheSubnetGroupsOutput, error) {
req, out := c.DescribeCacheSubnetGroupsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeCacheSubnetGroupsPages iterates over the pages of a DescribeCacheSubnetGroups operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeCacheSubnetGroups 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 DescribeCacheSubnetGroups operation.
// pageNum := 0
// err := client.DescribeCacheSubnetGroupsPages(params,
// func(page *elasticache.DescribeCacheSubnetGroupsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeCacheSubnetGroupsPages(input *DescribeCacheSubnetGroupsInput, fn func(*DescribeCacheSubnetGroupsOutput, bool) bool) error {
return c.DescribeCacheSubnetGroupsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeCacheSubnetGroupsPagesWithContext same as DescribeCacheSubnetGroupsPages 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 *ElastiCache) DescribeCacheSubnetGroupsPagesWithContext(ctx aws.Context, input *DescribeCacheSubnetGroupsInput, fn func(*DescribeCacheSubnetGroupsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeCacheSubnetGroupsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeCacheSubnetGroupsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeCacheSubnetGroupsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeEngineDefaultParameters = "DescribeEngineDefaultParameters"
// DescribeEngineDefaultParametersRequest generates a "aws/request.Request" representing the
// client's request for the DescribeEngineDefaultParameters 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 DescribeEngineDefaultParameters for more information on using the DescribeEngineDefaultParameters
// 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 DescribeEngineDefaultParametersRequest method.
// req, resp := client.DescribeEngineDefaultParametersRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeEngineDefaultParameters
func (c *ElastiCache) DescribeEngineDefaultParametersRequest(input *DescribeEngineDefaultParametersInput) (req *request.Request, output *DescribeEngineDefaultParametersOutput) {
op := &request.Operation{
Name: opDescribeEngineDefaultParameters,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"EngineDefaults.Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeEngineDefaultParametersInput{}
}
output = &DescribeEngineDefaultParametersOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeEngineDefaultParameters API operation for Amazon ElastiCache.
//
// Returns the default engine and system parameter information for the specified
// cache engine.
//
// 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 ElastiCache's
// API operation DescribeEngineDefaultParameters for usage and error information.
//
// Returned Error Codes:
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeEngineDefaultParameters
func (c *ElastiCache) DescribeEngineDefaultParameters(input *DescribeEngineDefaultParametersInput) (*DescribeEngineDefaultParametersOutput, error) {
req, out := c.DescribeEngineDefaultParametersRequest(input)
return out, req.Send()
}
// DescribeEngineDefaultParametersWithContext is the same as DescribeEngineDefaultParameters with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeEngineDefaultParameters 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 *ElastiCache) DescribeEngineDefaultParametersWithContext(ctx aws.Context, input *DescribeEngineDefaultParametersInput, opts ...request.Option) (*DescribeEngineDefaultParametersOutput, error) {
req, out := c.DescribeEngineDefaultParametersRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeEngineDefaultParametersPages iterates over the pages of a DescribeEngineDefaultParameters operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeEngineDefaultParameters 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 DescribeEngineDefaultParameters operation.
// pageNum := 0
// err := client.DescribeEngineDefaultParametersPages(params,
// func(page *elasticache.DescribeEngineDefaultParametersOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeEngineDefaultParametersPages(input *DescribeEngineDefaultParametersInput, fn func(*DescribeEngineDefaultParametersOutput, bool) bool) error {
return c.DescribeEngineDefaultParametersPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeEngineDefaultParametersPagesWithContext same as DescribeEngineDefaultParametersPages 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 *ElastiCache) DescribeEngineDefaultParametersPagesWithContext(ctx aws.Context, input *DescribeEngineDefaultParametersInput, fn func(*DescribeEngineDefaultParametersOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeEngineDefaultParametersInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeEngineDefaultParametersRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeEngineDefaultParametersOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeEvents = "DescribeEvents"
// DescribeEventsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeEvents 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 DescribeEvents for more information on using the DescribeEvents
// 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 DescribeEventsRequest method.
// req, resp := client.DescribeEventsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeEvents
func (c *ElastiCache) DescribeEventsRequest(input *DescribeEventsInput) (req *request.Request, output *DescribeEventsOutput) {
op := &request.Operation{
Name: opDescribeEvents,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeEventsInput{}
}
output = &DescribeEventsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeEvents API operation for Amazon ElastiCache.
//
// Returns events related to clusters, cache security groups, and cache parameter
// groups. You can obtain events specific to a particular cluster, cache security
// group, or cache parameter group by providing the name as a parameter.
//
// By default, only the events occurring within the last hour are returned;
// however, you can retrieve up to 14 days' worth of events if necessary.
//
// 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 ElastiCache's
// API operation DescribeEvents for usage and error information.
//
// Returned Error Codes:
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeEvents
func (c *ElastiCache) DescribeEvents(input *DescribeEventsInput) (*DescribeEventsOutput, error) {
req, out := c.DescribeEventsRequest(input)
return out, req.Send()
}
// DescribeEventsWithContext is the same as DescribeEvents with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeEvents 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 *ElastiCache) DescribeEventsWithContext(ctx aws.Context, input *DescribeEventsInput, opts ...request.Option) (*DescribeEventsOutput, error) {
req, out := c.DescribeEventsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeEventsPages iterates over the pages of a DescribeEvents operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeEvents 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 DescribeEvents operation.
// pageNum := 0
// err := client.DescribeEventsPages(params,
// func(page *elasticache.DescribeEventsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeEventsPages(input *DescribeEventsInput, fn func(*DescribeEventsOutput, bool) bool) error {
return c.DescribeEventsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeEventsPagesWithContext same as DescribeEventsPages 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 *ElastiCache) DescribeEventsPagesWithContext(ctx aws.Context, input *DescribeEventsInput, fn func(*DescribeEventsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeEventsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeEventsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeEventsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeReplicationGroups = "DescribeReplicationGroups"
// DescribeReplicationGroupsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeReplicationGroups 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 DescribeReplicationGroups for more information on using the DescribeReplicationGroups
// 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 DescribeReplicationGroupsRequest method.
// req, resp := client.DescribeReplicationGroupsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReplicationGroups
func (c *ElastiCache) DescribeReplicationGroupsRequest(input *DescribeReplicationGroupsInput) (req *request.Request, output *DescribeReplicationGroupsOutput) {
op := &request.Operation{
Name: opDescribeReplicationGroups,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeReplicationGroupsInput{}
}
output = &DescribeReplicationGroupsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeReplicationGroups API operation for Amazon ElastiCache.
//
// Returns information about a particular replication group. If no identifier
// is specified, DescribeReplicationGroups returns information about all replication
// groups.
//
// This operation is valid for Redis only.
//
// 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 ElastiCache's
// API operation DescribeReplicationGroups for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReplicationGroupNotFoundFault "ReplicationGroupNotFoundFault"
// The specified replication group does not exist.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReplicationGroups
func (c *ElastiCache) DescribeReplicationGroups(input *DescribeReplicationGroupsInput) (*DescribeReplicationGroupsOutput, error) {
req, out := c.DescribeReplicationGroupsRequest(input)
return out, req.Send()
}
// DescribeReplicationGroupsWithContext is the same as DescribeReplicationGroups with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeReplicationGroups 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 *ElastiCache) DescribeReplicationGroupsWithContext(ctx aws.Context, input *DescribeReplicationGroupsInput, opts ...request.Option) (*DescribeReplicationGroupsOutput, error) {
req, out := c.DescribeReplicationGroupsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeReplicationGroupsPages iterates over the pages of a DescribeReplicationGroups operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeReplicationGroups 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 DescribeReplicationGroups operation.
// pageNum := 0
// err := client.DescribeReplicationGroupsPages(params,
// func(page *elasticache.DescribeReplicationGroupsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeReplicationGroupsPages(input *DescribeReplicationGroupsInput, fn func(*DescribeReplicationGroupsOutput, bool) bool) error {
return c.DescribeReplicationGroupsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeReplicationGroupsPagesWithContext same as DescribeReplicationGroupsPages 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 *ElastiCache) DescribeReplicationGroupsPagesWithContext(ctx aws.Context, input *DescribeReplicationGroupsInput, fn func(*DescribeReplicationGroupsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeReplicationGroupsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeReplicationGroupsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeReplicationGroupsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeReservedCacheNodes = "DescribeReservedCacheNodes"
// DescribeReservedCacheNodesRequest generates a "aws/request.Request" representing the
// client's request for the DescribeReservedCacheNodes 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 DescribeReservedCacheNodes for more information on using the DescribeReservedCacheNodes
// 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 DescribeReservedCacheNodesRequest method.
// req, resp := client.DescribeReservedCacheNodesRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReservedCacheNodes
func (c *ElastiCache) DescribeReservedCacheNodesRequest(input *DescribeReservedCacheNodesInput) (req *request.Request, output *DescribeReservedCacheNodesOutput) {
op := &request.Operation{
Name: opDescribeReservedCacheNodes,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeReservedCacheNodesInput{}
}
output = &DescribeReservedCacheNodesOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeReservedCacheNodes API operation for Amazon ElastiCache.
//
// Returns information about reserved cache nodes for this account, or about
// a specified reserved cache node.
//
// 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 ElastiCache's
// API operation DescribeReservedCacheNodes for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReservedCacheNodeNotFoundFault "ReservedCacheNodeNotFound"
// The requested reserved cache node was not found.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReservedCacheNodes
func (c *ElastiCache) DescribeReservedCacheNodes(input *DescribeReservedCacheNodesInput) (*DescribeReservedCacheNodesOutput, error) {
req, out := c.DescribeReservedCacheNodesRequest(input)
return out, req.Send()
}
// DescribeReservedCacheNodesWithContext is the same as DescribeReservedCacheNodes with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeReservedCacheNodes 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 *ElastiCache) DescribeReservedCacheNodesWithContext(ctx aws.Context, input *DescribeReservedCacheNodesInput, opts ...request.Option) (*DescribeReservedCacheNodesOutput, error) {
req, out := c.DescribeReservedCacheNodesRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeReservedCacheNodesPages iterates over the pages of a DescribeReservedCacheNodes operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeReservedCacheNodes 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 DescribeReservedCacheNodes operation.
// pageNum := 0
// err := client.DescribeReservedCacheNodesPages(params,
// func(page *elasticache.DescribeReservedCacheNodesOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeReservedCacheNodesPages(input *DescribeReservedCacheNodesInput, fn func(*DescribeReservedCacheNodesOutput, bool) bool) error {
return c.DescribeReservedCacheNodesPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeReservedCacheNodesPagesWithContext same as DescribeReservedCacheNodesPages 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 *ElastiCache) DescribeReservedCacheNodesPagesWithContext(ctx aws.Context, input *DescribeReservedCacheNodesInput, fn func(*DescribeReservedCacheNodesOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeReservedCacheNodesInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeReservedCacheNodesRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeReservedCacheNodesOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeReservedCacheNodesOfferings = "DescribeReservedCacheNodesOfferings"
// DescribeReservedCacheNodesOfferingsRequest generates a "aws/request.Request" representing the
// client's request for the DescribeReservedCacheNodesOfferings 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 DescribeReservedCacheNodesOfferings for more information on using the DescribeReservedCacheNodesOfferings
// 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 DescribeReservedCacheNodesOfferingsRequest method.
// req, resp := client.DescribeReservedCacheNodesOfferingsRequest(params)
//
// err := req.Send()
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReservedCacheNodesOfferings
func (c *ElastiCache) DescribeReservedCacheNodesOfferingsRequest(input *DescribeReservedCacheNodesOfferingsInput) (req *request.Request, output *DescribeReservedCacheNodesOfferingsOutput) {
op := &request.Operation{
Name: opDescribeReservedCacheNodesOfferings,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "MaxRecords",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeReservedCacheNodesOfferingsInput{}
}
output = &DescribeReservedCacheNodesOfferingsOutput{}
req = c.newRequest(op, input, output)
return
}
// DescribeReservedCacheNodesOfferings API operation for Amazon ElastiCache.
//
// Lists available reserved cache node offerings.
//
// 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 ElastiCache's
// API operation DescribeReservedCacheNodesOfferings for usage and error information.
//
// Returned Error Codes:
// * ErrCodeReservedCacheNodesOfferingNotFoundFault "ReservedCacheNodesOfferingNotFound"
// The requested cache node offering does not exist.
//
// * ErrCodeInvalidParameterValueException "InvalidParameterValue"
// The value for a parameter is invalid.
//
// * ErrCodeInvalidParameterCombinationException "InvalidParameterCombination"
// Two or more incompatible parameters were specified.
//
// See also, https://docs.aws.amazon.com/goto/WebAPI/elasticache-2015-02-02/DescribeReservedCacheNodesOfferings
func (c *ElastiCache) DescribeReservedCacheNodesOfferings(input *DescribeReservedCacheNodesOfferingsInput) (*DescribeReservedCacheNodesOfferingsOutput, error) {
req, out := c.DescribeReservedCacheNodesOfferingsRequest(input)
return out, req.Send()
}
// DescribeReservedCacheNodesOfferingsWithContext is the same as DescribeReservedCacheNodesOfferings with the addition of
// the ability to pass a context and additional request options.
//
// See DescribeReservedCacheNodesOfferings 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 *ElastiCache) DescribeReservedCacheNodesOfferingsWithContext(ctx aws.Context, input *DescribeReservedCacheNodesOfferingsInput, opts ...request.Option) (*DescribeReservedCacheNodesOfferingsOutput, error) {
req, out := c.DescribeReservedCacheNodesOfferingsRequest(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return out, req.Send()
}
// DescribeReservedCacheNodesOfferingsPages iterates over the pages of a DescribeReservedCacheNodesOfferings operation,
// calling the "fn" function with the response data for each page. To stop
// iterating, return false from the fn function.
//
// See DescribeReservedCacheNodesOfferings 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 DescribeReservedCacheNodesOfferings operation.
// pageNum := 0
// err := client.DescribeReservedCacheNodesOfferingsPages(params,
// func(page *elasticache.DescribeReservedCacheNodesOfferingsOutput, lastPage bool) bool {
// pageNum++
// fmt.Println(page)
// return pageNum <= 3
// })
//
func (c *ElastiCache) DescribeReservedCacheNodesOfferingsPages(input *DescribeReservedCacheNodesOfferingsInput, fn func(*DescribeReservedCacheNodesOfferingsOutput, bool) bool) error {
return c.DescribeReservedCacheNodesOfferingsPagesWithContext(aws.BackgroundContext(), input, fn)
}
// DescribeReservedCacheNodesOfferingsPagesWithContext same as DescribeReservedCacheNodesOfferingsPages 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 *ElastiCache) DescribeReservedCacheNodesOfferingsPagesWithContext(ctx aws.Context, input *DescribeReservedCacheNodesOfferingsInput, fn func(*DescribeReservedCacheNodesOfferingsOutput, bool) bool, opts ...request.Option) error {
p := request.Pagination{
NewRequest: func() (*request.Request, error) {
var inCpy *DescribeReservedCacheNodesOfferingsInput
if input != nil {
tmp := *input
inCpy = &tmp
}
req, _ := c.DescribeReservedCacheNodesOfferingsRequest(inCpy)
req.SetContext(ctx)
req.ApplyOptions(opts...)
return req, nil
},
}
cont := true
for p.Next() && cont {
cont = fn(p.Page().(*DescribeReservedCacheNodesOfferingsOutput), !p.HasNextPage())
}
return p.Err()
}
const opDescribeServiceUpdates =