@travetto/model-redis 3.4.5 → 4.0.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/src/service.ts +1 -1
- package/support/service.redis.ts +1 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/model-redis",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0-rc.1",
|
|
4
4
|
"description": "Redis backing for the travetto model module.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -25,12 +25,12 @@
|
|
|
25
25
|
"directory": "module/model-redis"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@travetto/config": "^
|
|
29
|
-
"@travetto/model": "^
|
|
30
|
-
"redis": "^4.6.
|
|
28
|
+
"@travetto/config": "^4.0.0-rc.1",
|
|
29
|
+
"@travetto/model": "^4.0.0-rc.1",
|
|
30
|
+
"redis": "^4.6.12"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"@travetto/command": "^
|
|
33
|
+
"@travetto/command": "^4.0.0-rc.1"
|
|
34
34
|
},
|
|
35
35
|
"peerDependenciesMeta": {
|
|
36
36
|
"@travetto/command": {
|
package/src/service.ts
CHANGED
|
@@ -176,7 +176,7 @@ export class RedisModelService implements ModelCrudSupport, ModelExpirySupport,
|
|
|
176
176
|
this.client = redis.createClient(this.config.client);
|
|
177
177
|
await this.client.connect();
|
|
178
178
|
await ModelStorageUtil.registerModelChangeListener(this);
|
|
179
|
-
ShutdownManager.
|
|
179
|
+
ShutdownManager.onGracefulShutdown(() => this.client.disconnect(), this);
|
|
180
180
|
for (const el of ModelRegistry.getClasses()) {
|
|
181
181
|
for (const idx of ModelRegistry.get(el).indices ?? []) {
|
|
182
182
|
switch (idx.type) {
|
package/support/service.redis.ts
CHANGED