Questions tagged with Amazon ElastiCache for Redis

Content language: English

Sort by most recent

Browse through the questions and answers listed below or filter and sort to narrow down your results.

Cloudformation: update stack error Service: ElastiCache, Status Code: 400

Hi, Im using cdk to to create a stack with a redis cluster ```javascript const subnets = vpc.privateSubnets.map(subnet => subnet.subnetId); const subnetGroups = new CfnSubnetGroup( this, 'redisSubnets', { description: 'redis-subnets-${environmentName}', subnetIds: subnets } ); new RedisLogs( this, 'redisClusterLogs', environmentName ); const logsDeliveryConfiguration: CfnCacheCluster.LogDeliveryConfigurationRequestProperty = { logFormat: 'json', logType: 'slow-log', destinationDetails: { cloudWatchLogsDetails: { logGroup: `/redis/${environmentName}` } }, destinationType: 'cloudwatch-logs' }; const clusterProps: CfnCacheClusterProps = { cacheNodeType: 'cache.t3.micro', engine: 'redis', numCacheNodes: 1, autoMinorVersionUpgrade: true, vpcSecurityGroupIds: [securityGroup.securityGroupId], cacheSubnetGroupName: subnetGroups.ref, clusterName: `cluster-${environmentName}`, logDeliveryConfigurations: [logsDeliveryConfiguration], engineVersion: "6.2" }; this.redisCluster = new CfnCacheCluster( this, 'redis-cluster', clusterProps ); this.redisCluster.addDependsOn(subnetGroups) ``` cloudformation fails with this error into resource redisSubnets: ``` Resource handler returned message: "No modifications were requested. (Service: ElastiCache, Status Code: 400, Request ID: xxxxxxxx)" (RequestToken: xxxxxxx, HandlerErrorCode: GeneralServiceException) ``` Im using the same code for develop, certification environments, only in test environment causes this error This stack is in a bigger stack with several nested stacks like ecs, rds and another services, curiously, redis stack not have any changes
1
answers
0
votes
38
views
asked 22 days ago

Elasticache vertical scale up strange behaviour

Hi community! In my application, ElastiCache (Cluster mode disabled) is used in two scenarios, daily: 1. Intense usage, for about 3 hours, in which we need an improved network performance, and is run with cache.m6g.2xlarge 2. Light usage, for the rest of the day, in which a cache.m6g.large would be more than enough. We now use the 2xlarge 24/7, but would be nice to be able to vertically scale up and down during the intensive hours. However, when we do a scale up (large ⇾ 2xlarge) right before the heavy process, the behavior of the instance is not the same if we don't scale (keep 2xlarge for the whole day). Just for comparison, the first graph shows the Network Bytes In when there is a scale up right before the process, and the same metric when there isn't: ![With scale up, from cache.m6g.large to cache.m6g.2xlarge, reaching a max of 13Gb per minute](/media/postImages/original/IMox_zRCrAQyqlKEXGQo_Ixg) With scale up, from cache.m6g.large to cache.m6g.2xlarge, reaching a max of 13Gb per minute ![No scale up, instance cache.m6g.2xlarge reaches a max of 24Gb per minute](/media/postImages/original/IMkONubqtMS2SW_dQK_FAOAQ) No scale up, reaches a max of 24Gb per minute Note that the cache process only starts after the cluster Status is set to available. This drop in the Network Bytes In rate shouldn't be happening, and it is making the scale option to be impracticable to us. What is the point in giving an online scaling feature that does not work as it should after the scaling? Has anyone experienced something similar, and do you know of any alternatives to accomplish our goal, to provide performance only during the cache hours, keeping our costs reasonable? Thanks.
1
answers
1
votes
37
views
asked 25 days ago

getTemporaryPassword from Cognito for a specific user

Hi team, I have a validation flow of a cognito user that happen in tow steps: * **step1** 1 - add a new user in Cognito user pool using `adminCreateUser` API call 2 - add RELATED user info inside a dynamoDB table 3 - send an invitation link to the user (valid for 2 days) => when the user clicks the link he will be asked to provide only a new password while creating the user with `adminCreateUser` I assign to him a TemporaryPassword (generated by my code or let Cognito generate it) * **Step2** 1- When the user clicks the invitation link, gives his new password and confirm 2- on the backend I will call `adminInitiateAuth` to get `NEW_PASSWORD_REQUIRED` challenge 3- the call `respondToAuthChallenge` and provide `NEW_PASSWORD` that the user provided 4- user is confirmed in Cognito let's say the user will click on the invitation link 1.5 days after receiving it, provide his new password and confirm. then I call `adminInitiateAuth` ( point 2 of step 2) ==> for this, I need to provide the `TemporaryPassword` that I set in step 1 during `adminCreateUser` call. as step 2 is separate from step 1 and they can have a few days between them, is there an API method that allows me to get the TemporaryPassword from Cognito, so in Step 2 I can `adminInitiateAuth` and continue with `NEW_PASSWORD_REQUIRED` challenge. if I store the password temporarily in the Redis cache, the key can expire and I will lose the password (since if the first link is expired I can Resend the invitation link again and again always for the same user created in Step 1 with `adminCreateUser` API call, but I still need the TemporaryPassword for that user). how can I get the TemporaryPassword from Cognito for a specific user so that I can finalize step 2 and confirm the user (by doing `adminInitiateAuth` + `respondToAuthChallenge`) is it a bad practice if I set the TemporaryPassword **hard coded** during user creation `adminCreateUser` so I will always know it for `adminInitiateAuth`, then update the user's password with `respondToAuthChallenge` if I use Redis should the password be stored in encrypted form? can I store the password as is in DynamoDB user table along with the user's info without further encryption? (as the DDB user table itself is already encrypted with KMS) appreciate your Help!
1
answers
0
votes
45
views
Jess
asked 2 months ago