@travetto/cache
Advanced tools
Comparing version 1.0.0-rc.1 to 1.0.0-rc.2
@@ -10,3 +10,3 @@ { | ||
"dependencies": { | ||
"@travetto/compiler": "^1.0.0-rc.1" | ||
"@travetto/compiler": "^1.0.0-rc.2" | ||
}, | ||
@@ -36,4 +36,4 @@ "description": "Caching functionality with decorators for declarative use.", | ||
}, | ||
"version": "1.0.0-rc.1", | ||
"gitHead": "1aab475eaec81e90cc3a19fc7b68edb6510f8d23" | ||
"version": "1.0.0-rc.2", | ||
"gitHead": "019d593f07d43f679392e3e8fdfb4ab58e71da7a" | ||
} |
// @file-if redis | ||
import * as redis from 'redis'; | ||
import { ShutdownManager } from '@travetto/base'; | ||
import { CacheEntry } from '../types'; | ||
@@ -21,2 +23,3 @@ import { CacheSource } from '../source/core'; | ||
this.cl = new redis.RedisClient(this.config); | ||
ShutdownManager.onShutdown(__filename, () => this.cl.quit()); | ||
} | ||
@@ -23,0 +26,0 @@ |
@@ -122,3 +122,3 @@ type OrProm<T> = T | Promise<T>; | ||
/** | ||
* Post construction hook, used for async initliazations | ||
* Post construction hook, used for async initializations | ||
*/ | ||
@@ -143,3 +143,3 @@ postConstruct?(): OrProm<void>; | ||
* @param config The cache config to resolve against | ||
* @param entry The etnry to set | ||
* @param entry The entry to set | ||
*/ | ||
@@ -146,0 +146,0 @@ setWithAge(config: CacheConfig, entry: Partial<T> & { data: any, key: string }): OrProm<T>; |
31795
720