AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

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.

Note:

This is an asynchronous operation using the standard naming convention for .NET 4.5 or higher. For .NET 3.5 the operation is implemented as a pair of methods using the standard naming convention of BeginCreateCacheSecurityGroup and EndCreateCacheSecurityGroup.

Namespace: Amazon.ElastiCache
Assembly: AWSSDK.ElastiCache.dll
Version: 3.x.y.z

Syntax

C#
public virtual Task<CreateCacheSecurityGroupResponse> CreateCacheSecurityGroupAsync(
         CreateCacheSecurityGroupRequest request,
         CancellationToken cancellationToken
)

Parameters

request
Type: Amazon.ElastiCache.Model.CreateCacheSecurityGroupRequest

Container for the necessary parameters to execute the CreateCacheSecurityGroup service method.

cancellationToken
Type: System.Threading.CancellationToken

A cancellation token that can be used by other objects or threads to receive notice of cancellation.

Return Value


The response from the CreateCacheSecurityGroup service method, as returned by ElastiCache.

Exceptions

ExceptionCondition
CacheSecurityGroupAlreadyExistsException A cache security group with the specified name already exists.
CacheSecurityGroupQuotaExceededException The request cannot be processed because it would exceed the allowed number of cache security groups.
InvalidParameterCombinationException Two or more incompatible parameters were specified.
InvalidParameterValueException The value for a parameter is invalid.
TagQuotaPerResourceExceededException 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.

Version Information

.NET Core App:
Supported in: 3.1

.NET Standard:
Supported in: 2.0

.NET Framework:
Supported in: 4.5

See Also