@travetto/model-dynamodb 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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@travetto/model-dynamodb",
3
- "version": "3.4.5",
3
+ "version": "4.0.0-rc.1",
4
4
  "description": "DynamoDB backing for the travetto model module.",
5
5
  "keywords": [
6
6
  "typescript",
@@ -25,12 +25,12 @@
25
25
  "directory": "module/model-dynamodb"
26
26
  },
27
27
  "dependencies": {
28
- "@aws-sdk/client-dynamodb": "^3.454.0",
29
- "@travetto/config": "^3.4.4",
30
- "@travetto/model": "^3.4.5"
28
+ "@aws-sdk/client-dynamodb": "^3.506.0",
29
+ "@travetto/config": "^4.0.0-rc.1",
30
+ "@travetto/model": "^4.0.0-rc.1"
31
31
  },
32
32
  "peerDependencies": {
33
- "@travetto/command": "^3.4.3"
33
+ "@travetto/command": "^4.0.0-rc.1"
34
34
  },
35
35
  "peerDependenciesMeta": {
36
36
  "@travetto/command": {
package/src/service.ts CHANGED
@@ -187,7 +187,7 @@ export class DynamoDBModelService implements ModelCrudSupport, ModelExpirySuppor
187
187
  async postConstruct(): Promise<void> {
188
188
  this.client = new dynamodb.DynamoDB({ ...this.config.client });
189
189
  await ModelStorageUtil.registerModelChangeListener(this);
190
- ShutdownManager.onShutdown(this, () => this.client.destroy());
190
+ ShutdownManager.onGracefulShutdown(async () => this.client.destroy(), this);
191
191
  }
192
192
 
193
193
  // Storage
@@ -1,7 +1,6 @@
1
- import { Env } from '@travetto/base';
2
1
  import type { CommandService } from '@travetto/command';
3
2
 
4
- const version = Env.get('DYNAMODB_VERSION', '2.0.0');
3
+ const version = process.env.DYNAMODB_VERSION || '2.0.0';
5
4
 
6
5
  export const service: CommandService = {
7
6
  name: 'dynamodb',