Skip to content
This repository has been archived by the owner on Sep 20, 2022. It is now read-only.

Commit

Permalink
adding support for redis 5.0.0 & 5.0.3 (#606)
Browse files Browse the repository at this point in the history
* adding support for redis 5.0.0 & 5.0.3

* updated test version to latest
  • Loading branch information
ndpete authored and bwinterton committed Apr 2, 2019
1 parent 08fe393 commit fdca47f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/redis/handel.yml
Expand Up @@ -5,7 +5,7 @@ environments:
cache:
type: redis
instance_type: cache.m3.medium
redis_version: 4.0.10
redis_version: 5.0.3
description: example description
read_replicas: 1
cache_parameters:
Expand Down
6 changes: 6 additions & 0 deletions handel/src/services/redis/index.ts
Expand Up @@ -74,6 +74,9 @@ function getCacheParameterGroupFamily(redisVersion: string): string {
else if (redisVersion.startsWith('4.0')) {
return 'redis4.0';
}
else if (redisVersion.startsWith('5.0')) {
return 'redis5.0';
}
else {
throw new Error(`Unsupported Redis major/minor version: '${redisVersion}'`);
}
Expand All @@ -95,6 +98,9 @@ function getDefaultCacheParameterGroup(redisVersion: string): string {
else if (redisVersion.startsWith('4.0')) {
return 'default.redis4.0';
}
else if (redisVersion.startsWith('5.0')) {
return 'default.redis5.0';
}
else {
throw new Error(`Unsupported Redis major/minor version: '${redisVersion}'`);
}
Expand Down
2 changes: 1 addition & 1 deletion handel/test/services/redis/redis-test.ts
Expand Up @@ -50,7 +50,7 @@ describe('redis deployer', () => {
sandbox = sinon.createSandbox();
serviceParams = {
type: 'redis',
redis_version: '3.2.4',
redis_version: '5.0.3',
instance_type: 'cache.t2.micro'
};
serviceContext = new ServiceContext(appName, envName, 'FakeService', new ServiceType(STDLIB_PREFIX, 'redis'), serviceParams, accountConfig);
Expand Down

0 comments on commit fdca47f

Please sign in to comment.