/// <summary> /// Create a redis cache, or replace (overwrite/recreate, with potential /// downtime) an existing cache /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='name'> /// The name of the redis cache. /// </param> /// <param name='parameters'> /// Parameters supplied to the CreateOrUpdate redis operation. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <RedisResourceWithAccessKey> CreateOrUpdateAsync(this IRedisOperations operations, string resourceGroupName, string name, RedisCreateOrUpdateParameters parameters, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, name, parameters, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }